Vertical cavity surface-emitting lasers (VCSELs) have made indispensable contributions to the development of modern optoelectronic technologies. However, arbitrary beam shaping of VCSELs within a compact system has remained inaccessible until now. The emerging ultra-thin flat optical structures, namely metasurfaces, offer a powerful technique to manipulate electromagnetic fields with subwavelength spatial resolution. Here, we show that the monolithic integration of dielectric metasurfaces with VCSELs enables remarkable arbitrary control of the laser beam profiles, including self-collimation, Bessel and Vortex lasers, with high efficiency. Such wafer-level integration of metasurface through VCSEL-compatible technology simplifies the assembling process and preserves the high performance of the VCSELs. We envision that our approach can be implemented in various wide-field applications, such as optical fibre communications, laser printing, smartphones, optical sensing, face recognition, directional displays and ultra-compact light detection and ranging (LiDAR).