We investigate resonantly excited photoluminescence from a Eu,O-codoped GaN layer embedded into a microcavity, consisting of an AlGaN/GaN distributed Bragg reflector and a Ag reflecting mirror. The microcavity is responsible for a 18.6-fold increase of the Eu emission intensity at ∼10K, and a 21-fold increase at room temperature. We systematically investigate the origin of this enhancement, and we conclude that it is due to the combination of several effects including, the lifetime shortening of the Eu emission, the strain-induced piezoelectric effect, and the increased extraction and excitation field efficiencies. This study paves the way for an alternative method to enhance the photoluminescence intensity in rare-earth doped semiconductor structures.