Abstract: The RKKY interaction determines the magnetic structure of rare-earth metals and is caused by RE s,p valence electrons. Direct observation of how the electronic structure depends on the distance could be very useful - in particular in view of magnetic transition-metal--noble-metal sandwich structures, where s,p-electrons in quantum-well states have been identified as the cause of long-range oscillatory magnetic coupling. We have used the particular epitaxy and electronic structures of Gd and W in order to confine Gd s,d electrons in ultrathin overlayers and observe sharp quantum-well peaks in photoemission spectra. As a first application, the Gd band dispersion is determined based on a phase-accumulation-model analysis of the data resolving a current dispute on the nature of Gd valence band states.