Optical microtraps provide a strong spatial confinement for laser-cooled atoms. They can, e.g., be realized with strongly focused trapping light beams or the optical near fields of nano-scale waveguides and photonic nanostructures. Atoms in such traps often experience strongly spatially varying AC Stark shifts which are proportional to the magnetic quantum number of the respective energy level. These inhomogeneous fictitious magnetic fields can cause a displacement of the trapping potential that depends on the Zeeman state.