We demonstrated an over 20% wall plug efficiency of an on-wafer GaN-based vertical-cavity surface-emitting laser (VCSEL) with a 5 μm aperture. The cavity length of the VCSEL was 4λ optical length, containing a 3.7λ part of GaN-based layers controlled with an in situ reflectivity spectra measurement and a 0.3λ part of an ITO electrode and a Nb2O5 spacer layer adjusted with an ex situ measurement. In order to calibrate the thickness of ITO and N2O5, we directly evaluated resonance wavelength shifts of a 4λ GaN cavity test structure with additional ITO or N2O5 depositions on the cavity. We then fabricated GaN-based VCSELs with various aperture sizes from 5 to 20 μm by implementing the tuned ITO electrode and the tuned N2O5 spacer layer into the 4λ cavity of the VCSELs. The GaN-based VCSEL with an 8 μm aperture showed a light output power of 13.1 mW and an emission wavelength of 417.7 nm, which was only a 0.3 nm away from a designed wavelength.