In this paper, a compact endfire antenna array with low-profile, small clearance, and wideband operation is proposed for millimeter-wave (mmWave) fifth-generation (5G) mobile terminals. The wideband operation is achieved by exciting two identical bow-tie dipoles inserted on both sides of a multilayer substrate fed by an asymmetric open-end stripline to slotline transition. The antenna performance is significantly improved by introducing a set of vertical metallic vias. The proposed antenna element can achieve 29 % from 24.2 GHz to 32.4 GHz with a peak realized gain that varies from 3.5 dBi to 4.5 dBi. A linear 4-element antenna array is arranged and fabricated to verify the proposed antenna beamforming capabilities. The simulated and measured bandwidth achieves a wide range of 34.4 % (24-34 GHz) to support 26, 28, and 30 GHz 5G mmWave bands with an isolation level better than 20 dB and a peak realized gain over the interested bands ranging from 7.56 to 8.14 dBi. The simulated array scanning angle is ± 68 • at 28 GHz within 3-dB gain deterioration. Furthermore, the simulated spherical coverage has met the requirements of 3GPP standards which make the proposed antenna array a promising candidate to be integrated within mmWave 5G mobile devices. INDEX TERMS 5G, antenna array, beamforming, endfire, mmWave bands, mobile terminal, wideband