The electronic properties of crystals with a layered structure can be radically altered by the intercalation, between the layers, of guest species that act as electron donors or acceptors.Such studies have been performed extensively on graphite, transition-metal dichalcogenides and oxide bronzes . Interest in redox intercalation reactions  has increased recently because the high-transition-temperature (high-Tc) superconductors based on copper oxide also have layered structures, the superconductivity occurring within two-dimensional CuO2 planes separated by charge-reservoir oxide layers . Similarly, in metal-doped fullerenes, which show relatively high transition temperatures, the electron donor atoms sit in the interstitial sites between adjacent fullerene balls . In a previous study , we described a layered nitride, beta-ZrNCl, consisting of Zr-N double layers sandwiched between two close-packed chlorine layers. On lithium intercalation, the crystal changed from a semiconductor to a metal, and became a super-conductor at 13 K. Here we report the properties of the isostructural compound beta-HfNCl. After electron-doping the crystal by lithium intercalation, we observe superconductivity with a Tc of up to 25.5 K. This transition temperature is higher than that observed in any intermetallic compound, and suggests that layered nitride structures may offer transition temperatures comparable to those observed in layered copper oxide structures.