Membrane trafficking is an essential cellular process conserved across all eukaryotes, which regulates the uptake or release of macromolecules from cells, the composition of cellular membranes and organelle biogenesis. It influences numerous aspects of cellular organisation, dynamics and homeostasis, including nutrition, signalling and cell architecture. Not surprisingly, malfunction of membrane trafficking is linked to many serious genetic, metabolic and neurological disorders. It is also often hijacked during viral infection, enabling viruses to accomplish many of the main stages of their replication cycle, including entry into and egress from cells. The appropriation of membrane trafficking by viruses has been studied since the birth of cell biology and has helped elucidate how this integral cellular process functions. In this Review, we discuss some of the different strategies viruses use to manipulate and take over the membrane compartments of their hosts to promote their replication, assembly and egress.