This article puts forward an indirect cooperative relative localization method to estimate the position of unmanned aerial vehicles (UAVs) relative to their neighbors based solely on distance and self-displacement measurements in GPS denied environments. Our method consists of two stages. Initially, assuming no knowledge about its own and neighbors’ states and limited by the environment or task constraints, each unmanned aerial vehicle (UAV) solves an active 2D relative localization problem to obtain an estimate of its initial position relative to a static hovering quadcopter (a.k.a. beacon), which is subsequently refined by the extended Kalman filter to account for the noise in distance and displacement measurements. Starting with the refined initial relative localization guess, the second stage generalizes the extended Kalman filter strategy to the case where all unmanned aerial vehicles (UAV) move simultaneously. In this stage, each unmanned aerial vehicle (UAV) carries out cooperative localization through the inter-unmanned aerial vehicle distance given by ultra-wideband and exchanging the self-displacements of neighboring unmanned aerial vehicles (UAV). Extensive simulations and flight experiments are presented to corroborate the effectiveness of our proposed relative localization initialization strategy and algorithm.