Rapid advances in genetics, genomics, and imaging have given insight into the molecular and cellular basis of behaviour in a variety of model organisms with unprecedented detail and scope. It is increasingly routine to isolate behavioural mutants, clone and characterise mutant genes, and discern the molecular and neural basis for a behavioural phenotype. Conversely, reverse genetic approaches have made it possible to straightforwardly identify genes of interest in whole-genome sequences and generate mutants that can be subjected to phenotypic analysis. In this latter approach, it is the phenotyping that presents the major bottleneck; when it comes to connecting phenotype to genotype in freely behaving animals, analysis of behaviour itself remains superficial and time consuming. However, many proof-of-principle studies of automated behavioural analysis over the last decade have poised the field on the verge of exciting developments that promise to begin closing this gap. In the broadest sense, our goal in this chapter is to explore what we can learn about the genes involved in neural function by carefully observing behaviour. This approach is rooted in model organism genetics but shares ideas with ethology and neuroscience, as well as computer vision and bioinformatics. After introducing C. elegans as a model, we will survey the research that has led to the current state of the art in worm behavioural phenotyping and present current research that is transforming our approach to behavioural genetics.