A programmable metasurface antenna based on electrically tunable elements operating in 5G millimeter‐wave band, which has the features of low cost, easy manufacturing, low profile, easy integration with planar circuits, is proposed herein. The prototype consists of a 128‐element metasurface array, an 8‐channel beamforming chip as equal amplitude power divider networks, and a control network. Elements mounted with varactors to realize different states are controlled by DC bias signal from the back of a printed circuit board (PCB). By assigning different voltage values, array coding can be dynamically changed, thereby realizing beam steering. Both element dimensions and its location along substrate integrated waveguide (SIW) are optimized to better antenna performance. Experiment results show that the proposed metasurface can achieve not only the scanning range of ±70° for unidirectional beam in azimuth and ±40° in elevation but also ±50° for dual beam in azimuth. The whole prototype is fabricated based on PCB technologies, and good agreements among simulated and measured results are obtained. The proposed electrically tunable metasurface array is a good alternative to the traditional expensive phased array and has a great potential application prospect in radar and communication systems.