Trivalent rare-earth (RE=Eu, Sm) doped transparent nano-glass–ceramics comprising BaYF5 nanocrystals were successfully obtained by appropriate heat-treatment of the corresponding precursor sol–gel glasses. Their structural and spectroscopic properties were investigated and compared with those for Eu3+-doped-BaYF5 nanocrystals prepared by a solvothermal method. X-ray Diffraction, Transmission Electron Microscopy and Energy Dispersive X-ray Spectroscopy measurements confirmed the distribution of BaYF5 nanocrystals in the glass matrix, presenting a cubic phase structure with space group Fm-3m. In order to achieve a further structural characterization, the luminescence properties of the Eu3+ and Sm3+ dopants were also used as sensitive probes. The reduction in the emission intensities of hypersensitive transitions 5D0→7F2 and 4G5/2→6H9/2 for Eu3+ and Sm3+ ions respectively, along with time-resolved measurements, confirm the distribution of a significant fraction of RE ions into the fluoride nanocrystal environment. These results suggest that BaYF5 nano-glass–ceramics doped with Eu3+ or Sm3+ can be considered as potential red-emitting phosphors for the development of white LEDs under near UV excitation.