We present an experimental and theoretical study of the energy transfer between modes during the tapering process of an optical nanofiber through spectrogram analysis. The results allow optimization of the tapering process, and we measure transmission in excess of 99.95% for the fundamental mode. We quantify the adiabaticity condition through calculations and place an upper bound on the amount of energy transferred to other modes at each step of the tapering, giving practical limits to the tapering angle. (C) 2013 Optical Society of America