We demonstrate the interplay between quantum well states in Pd and the magnetic anisotropy in Pd/Co/Cu (0 0 1) by combined scanning tunneling spectroscopy (STS) and magneto optical Kerr effect (MOKE) measurements. Low temperature scanning tunneling spectroscopy reveals occupied and unoccupied quantum well states (QWS) in atomically flat Pd films on Co/Cu (0 0 1). These states give rise to sharp peaks in the differential conductance spectra. A quantitative analysis of the spectra reveals the electronic dispersion of the Pd (0 0 1) d-band (-type) along the -X direction. In situ MOKE experiments on Pd/Co/Cu (1, 1, 13) uncover a periodic variation of the in-plane uniaxial magnetic anisotropy as a function of Pd thickness with a period of 6 atomic layers Pd. STS shows that QWS in Pd cross the Fermi level with the same periodicity of 6 atomic layers. Backed by previous theoretical work we ascribe the variation of the magnetic anisotropy in Co to QWS in the Pd overlayer. Our results suggest a novel venue towards tailoring uniaxial magnetic anisotropy of ferromagnetic films by exploiting QWS in an adjacent material with large spin–orbit coupling.