  We present a first-principles derivation of spatial atomic-sublevel
decoherence near dielectric and metallic surfaces. The theory is based on the
electromagnetic-field quantization in absorbing dielectric media. We derive an
expression for the time-variation of the off-diagonal matrix element of the
atomic density matrix for arbitrarily shaped substrates. For planar
multilayered substrates we find that for small lateral separations of the
atom's possible positions the spatial coherence decreases quadratically with
the separation and inversely to the squared atom-surface distance.
