Compounds of transition metals are generally colored because of d-d transitions. In these compounds, the d-orbitals are split into two energy levels due to the ligand field. When electrons in the lower energy d-orbitals absorb visible light, they get excited to the higher energy d-orbitals. The wavelength of light absorbed corresponds to the energy difference between the split d-orbitals, and the remaining transmitted light gives the color of the compound. This phenomenon is common in transition metal complexes, particularly when the metal has an incomplete d-orbital configuration. The presence of ligands and the metal’s oxidation state also affect the color.