We simulate the ionization contrast in field ion microscopy arising from the electronic structure of the imaged surface. For this DFT calculations of the electrified surface are combined with the Tersoff-Hamann approximation to electron tunneling. The approach allows to explain the chemical contrast observed for NiRe alloys.