The spectra (rotational, rotation–vibrational or electronic) of diatomic molecules due to transitions involving only closed-shell (1Σ ) electronic states follow very regular, simple patterns and their theoretical analysis is usually straightforward. On the other hand, open-shell electronic states lead to more complicated spectral patterns and, moreover, often appear as a manifold of closely lying electronic states, leading to perturbed spectra of even greater complexity. This is especially true when at least one of the atoms is a transition metal. Traditionally these complex cases have been analysed using approaches based on perturbation theory, with semi-empirical parameters determined by fitting to spectral data. Recently the needs of two rather diverse scientific areas have driven the demand for improved theoretical models of open-shell diatomic systems based on an ab initio approach; these areas are ultracold chemistry and the astrophysics of ‘cool’ stars, brown dwarfs and most recently extrasolar planets. However, the complex electronic structure of these molecules combined with the accuracy requirements of high-resolution spectroscopy render such an approach particularly challenging. This review describes recent progress in developing methods for directly solving the effective Schrödinger equation for open-shell diatomic molecules, with a focus on molecules containing a transtion metal. It considers four aspects of the problem: (i) the electronic structure problem; (ii) non-perturbative treatments of the curve couplings; (iii) the solution of the nuclear motion Schrödinger equation; (iv) the generation of accurate electric dipole transition intensities. Examples of applications are used to illustrate these issues.