In this study, CeO2 and composites of (La, Er)- and (La,Y)- codoped CeO2 were prepared via the sol-gel method and characterized by X-ray diffraction (XRD), Brunauer-Emmett-Teller (BET) analysis, field-emission scanning electron microscopy (FESEM), scanning transmission electron microscopy (STEM), Fourier-transform infra-red spectroscopy (FT-IR), energy dispersive X-ray spectroscopy (EDX), Raman spectroscopy, UV/vis absorption, and photoluminescence spectra, respectively. The XRD results indicated that the undoped CeO2 and the compounds were well crystallized with a cubic structure. The FESEM images illustrated that the average particle size was in the range of 10-20 mu m. The synthesized compounds were used to degrade methylene blue dye. The variance in degradation percentages was due to the oxygen vacancies created by doping La, Er, and Y into the CeO2 lattice structure. The absorption spectra indicated that CeO2 and CeO2:La3+ (Er3+, Y3+) had different band gaps that varied between 3.03 and 2.58 eV. In addition, the (La,Y)-doped CeO2 showed predominantly red emissions, whereas the (La, Er)-doped CeO2 exhibited predominantly green emissions.