Thermodynamic data for the substitution of silicon and manganese in cementite have been estimated using first-principles methods in order to aid the design of steels where it is necessary to control the precipitation of this phase. The need for the calculations arises from the fact that for silicon the data cannot be measured experimentally; manganese is included in the analysis to allow a comparison with its known behaviour. The calculations for Fe3C, (Fe11Si4c)C4, (Fe11Si8d)C4, (Fe11Mn4c)C4 and (Fe11Mn8d)C4 are based on the total energy all-electron full-potential linearized augmented plane-wave method within the generalized gradient approximation to density functional theory. The output includes the ground state lattice constants, atomic positions and bulk moduli. It is found that (Fe11Si4c)C4 and (Fe11Si8d)C4 have about 52 and 37 kJ greater formation energy when compared with a mole of unit cells of pure cementite, whereas the corresponding energy for (Fe11Mn4c)C4 and (Fe11Mn8d)C4 is less by about 5 kJ mol1. These results for manganese match closely with published trends and data; a similar comparison is not possible for silicon but we correctly predict that the solubility in cementite should be minimal.