Photoluminescence characteristics of porous silicon layers (PSLs) doped with Er or Yb ions are studied. 10μm thick PSLs with a luminescence centered at ∼ 0.8μm are formed by anodic etching of p-type silicon wafers of several Ω-cm resistivity. Rare-earth ions are electrochemically incorporated into PSLs. The Er3+-related luminescence at 1.54μm as well as the Yb3+-related luminescence at 1.0μm is observed at room temperature after annealing at high temperatures (>900°C). The Er-related luminescence is enhanced after annealing in O2, whereas the Yb3+-related luminescence needs oxygen-free atmosphere (H2) for the optical activation. The luminescence decay time of the rare earth ions as well as the host PSLs is measured and the energy transfer mechanism is discussed.