Density functional theory (DFT) provides a theoretical framework for efficient and fairly accurate calculations of the electronic structure of molecules and crystals. The main features of density functional theory are described and DFT methods are compared with wavefunction-based methods like the Hartree-Fock approach. Some recent applications of DFT to spin crossover complexes are reviewed, e.g., the calculation of Mossbauer parameters, of vibrational modes and of differences of entropy, vibrational energy, and total electronic energy between high-spin and low-spin isomers.