These lectures deal with our current knowledge of the matter distribution in the universe, focusing on how this is studied via the large-scale structure seen in galaxy surveys. We first assemble the necessary basics needed to understand the development of density fluctuations in an expanding universe, and discuss how galaxies are located within the dark-matter density field. Results from the 2dF Galaxy Redshift Survey are presented and contrasted with theoretical models. We show that the combination of large-scale structure and data on microwave-background anisotropies can eliminate almost all degeneracies, and yield a completely specified cosmological model. This is the concordance universe: a geometrically flat combination of vacuum energy and cold dark matter. The study of cosmic structure is able to establish this in a manner independent of external information, such as the Hubble diagram; this extra information can however be used to limit non-standard alternatives, such as a variable equation of state for the vacuum.