Metal carbides are good candidates to contact carbon-based semiconductors ͑SiC, diamond, and carbon nanotubes͒. Here, we report on an in situ study of carbide formation during the solid-state reaction between thin films. The solid-state reaction was examined between 11 transition metals ͑W, Mo, Fe, Cr, V, Nb, Mn, Ti, Ta, Zr, and Hf͒ and an amorphous carbon layer. Capping layers ͑C or TiN͒ of different thicknesses were applied to prevent oxidation. Carbide formation is evidenced for nine metals and the phases formed have been identified ͑for a temperature ranging from 100 to 1100°C͒. W first forms W 2 C and then WC; Mo forms Mo 2 C; Fe forms Fe 3 C; Cr first forms metastable phases Cr 2 C and Cr 3 C 2−x , and finally forms Cr 3 C 2 ; V forms VC x ; Nb transforms into Nb 2 C followed by NbC; Ti forms TiC; Ta first forms Ta 2 C and then TaC; and Hf transforms into HfC. The activation energy for the formation of the various carbide phases has been obtained by in situ x-ray diffraction.