Twitching motility is a unique form of bacterial propulsion on solid surfaces associated with cycles of extension, tethering and retraction of type IV pili (T4P). Although investigations over the last two decades in a number of species have identified the majority of the genes involved in this process, we are still learning how these pili are assembled and the mechanics by which bacteria use T4P to drag themselves from one place to another. Among the puzzles that remain to be solved is the mechanism by which hydrolysis of ATP is coupled to pilus assembly and disassembly, and how the cell envelope structure is modified to accommodate the passage of the pilus through the periplasm. Unravelling of these and other enigmas in the T4P system will not only teach us more about these important colonization and virulence factors, but also help us to understand related processes such as type II secretion, which relies on a set of proteins homologous to those in the T4P system, and bacterial conjugation, involving retractable pili belonging to the F-like subgroup of the type IV secretion family. This review focuses on recent discoveries relating to the assembly and function of T4P in generation of twitching motility.