How are neuronal representations of the spatial environment generated at the level of synapses, neurons, and neuronal circuits? Neurons in the hippocampal formation produce striking spatial firing patterns that may provide the brain with a cognitive map of the environment. In this talk I will show how we combine computational modelling, in vivo and in vitro recordings to understand how spatially modulated firing is generated at the synaptic, cellular, and network level. We address this question in several key circuits that are critical for spatial cognition and memory, such as the medial entorhinal cortex, the dentate gyrus, and the medial prefrontal cortex.