The manipulation of light-matter interactions by quantum control of atomic levels has had a profound impact on optical sciences. Such manipulation has many applications, including nonlinear optics at the few-photon level, slow light, lasing without inversion and optical quantum information processing. The critical underlying technique is electromagnetically induced transparency, in which quantum interference between transitions in multilevel atoms renders an opaque medium transparent near an atomic resonance. With the advent of high-brilliance, accelerator-driven light sources such as storage rings or X-ray lasers, it has become attractive to extend the techniques of optical quantum control to the X-ray regime. Here we demonstrate electromagnetically induced transparency in the regime of hard X-rays, using the 14.4-kiloelectronvolt nuclear resonance of the Mössbauer isotope iron-57 (a two-level system). We exploit cooperative emission from ensembles of the nuclei, which are embedded in a low-finesse cavity and excited by synchrotron radiation. The spatial modulation of the photonic density of states in a cavity mode leads to the coexistence of superradiant and subradiant states of nuclei, respectively located at an antinode and a node of the cavity field. This scheme causes the nuclei to behave as effective three-level systems, with two degenerate levels in the excited state (one of which can be considered metastable). The radiative coupling of the nuclear ensembles by the cavity field establishes the atomic coherence necessary for the cancellation of resonant absorption. Because this technique does not require atomic systems with a metastable level, electromagnetically induced transparency and its applications can be transferred to the regime of nuclear resonances, establishing the field of nuclear quantum optics.