The application of topology, the mathematics of conserved properties under continuous deformations, is creating a range of new opportunities throughout photonics. This field was inspired by the discovery of topological insulators, in which interfacial electrons transport without dissipation, even in the presence of impurities. Similarly, the use of carefully designed wavevector-space topologies allows the creation of interfaces that support new states of light with useful and interesting properties. In particular, this suggests unidirectional waveguides that allow light to flow around large imperfections without back-reflection. This Review explains the underlying principles and highlights how topological effects can be realized in photonic crystals, coupled resonators, metamaterials and quasicrystals.