Selecting stable reference genes for reverse transcription quantitative real‐time polymerase chain reaction analysis is critically important for gene expression. Bradysia odoriphaga is the most serious pest of Chinese chives, but our knowledge of its genetics is limited. In the present study, five housekeeping genes (β‐Actin, α‐Tubulin, RPS7, GAPDH and 18S rRNA) were cloned from B. odoriphaga using the combined techniques of reverse transcription polymerase chain reaction with rapid amplification of cDNA ends. The five genes, together with RPS15, were quantified for transcription stability in B. odoriphaga under various experimental conditions. Their expression stability was evaluated using four different algorithms (a comparative ΔCt method, GeNorm, NormFinder and BestKeeper). Additionally, we used an online Web‐based tool (RefFinder) to assign an overall final rank to each candidate gene. These analyses identified 18S, RPS15 and RPS7 as the most stable reference genes across developmental stages. 18S, RPS7 and Tubulin were the most stable reference genes for monitoring gene expression across different tissues of adults. RPS7, GAPDH and Tubulin were selected as the best reference genes across different larval tissues. GAPDH and RPS15 were selected to normalize gene expression for experiments of insecticide treatments. Actin and GAPDH are considered suitable reference genes in experiments of temperature treatments. Actin and Tubulin are considered suitable reference genes for starvation experiments. This study provides an important supplement of suitable reference genes for B. odoriphaga and these results provide clues toward the understanding of the genes’ biological functions in B. odoriphaga.