ABSTRACT Stimulated emission depletion (STED) fluorescence nanoscopy allows the three-dimensional (3D) visualization of nanoscale subcellular structures, providing unique insights into their spatial organization. However, 3D-STED imaging and quantification of dense features are obstructed by the low signal-to-background ratio (SBR), resulting from optical aberrations and out-of-focus background. Here, combining with adaptive optics, we present an easy-to-implement and flexible method to improve SBR by dynamic phase switching. By switching to a counterclockwise vortex phase mask and a top-hat one with an incorrect inner radius, the depletion pattern features a nonzero-intensity center, enabling accurate background recordings. When the recorded background is subtracted from the aberration-corrected 3D-STED image, the SBR in dense sample areas can be improved by a factor of 3–6 times. We demonstrate our method on various dense subcellular structures, showing more advantages than the software-based background subtraction algorithms. Abstract Figure