Contact tracing, followed by treatment or isolation, is a key control measure in the battle against infectious diseases. It is an extreme form of locally targeted control, and as such has the potential to be highly efficient when dealing with low numbers of cases. For this reason it is frequently used to combat sexually transmitted diseases and new invading pathogens. Accurate modelling of contact tracing requires explicit information about the disease–transmission pathways from each individual, and hence the network of contacts. Here, pairwise–approximation methods and full stochastic simulations are used to investigate the utility of contact tracing. A simple relationship is found between the efficiency of contact tracing necessary for eradication and the basic reproductive ratio of the disease. This holds for a wide variety of realistic situations including heterogeneous networks containing core–groups or super–spreaders, and asymptomatic individuals. Clustering (transitivity) within the transmission network is found to destroy the relationship, requiring lower efficiency than predicted.