The reflection and luminescence spectra of a CdTe/CdMgTe heterostructures doped with iodine are studied. Iodine was introduced either into a barrier layer or into a wide CdTe quantum well. It is shown how the doping method and level affect the spectra and the temperature dependence of the quantum well exciton emission intensity. Keywords: heterostructure CdTe/CdMgTe, doping, exciton, luminescence.