We present ab-initio calculations for the electronic structure of 3d impurities on Fe and Ni(001) surfaces. The calculations are based on local density functional theory and apply a KKR Green's function method for impurities on surfaces. We consider single 3d impurities as adatoms on hollow sites in the first ‘vacuum’ layer and as substitutional impurities in the surface layer. For Fe, Mn, and Cr impurities the moments are considerably enhanced compared to the bulk, but the moments of the adatom and the surface site differ surprisingly little in size. While a Mn adatom couples ferromagnetically to the bulk moments, we find antiferromagnetic coupling for the surface position. We also perform calculations for adatom dimers and determine their magnetic coupling. On the Ni(001) surface the 3d moments are more strongly enhanced than on the Fe surface and within the 3d series a broad two state region exists.