The synthesis of functionalized nitrogen heterocycles is integral to discovering, manufacturing and evolving high-value materials. The availability of effective strategies for heterocycle synthesis often biases the frequency of specific ring systems over others in the core structures of bioactive leads. For example, while the six- and five-membered piperidine and pyrrolidine are widespread in medicinal chemistry libraries, the seven-membered azepane is essentially absent and this leaves open a substantial area of three-dimensional chemical space. Here we report a strategy to prepare complex azepanes from simple nitroarenes by photochemical dearomative ring expansion centred on the conversion of the nitro group into a singlet nitrene. This process is mediated by blue light, occurs at room temperature and transforms the six-membered benzenoid framework into a seven-membered ring system. A following hydrogenolysis provides the azepanes in just two steps. We have demonstrated the utility of the strategy with the synthesis of several azepane analogues of piperidine drugs.