Urban areas have both positive and negative influences on wildlife. For terrestrial mammals, one of the principal problems is the risk associated with moving through the environment while foraging. We examined nocturnal patterns of movement of urban-dwelling hedgehogs in relation to (1) the risks posed by predators and motor vehicles and (2) nightly weather patterns. Hedgehogs preferentially utilized the gardens of semidetached and terraced houses. However, females, but not males, avoided the larger back gardens of detached houses, which contain more of the habitat features selected by badgers. This difference in the avoidance of predation risk is probably associated with sex differences in breeding behaviour. Differences in nightly movement patterns were consistent with strategies associated with mating behaviour and the accumulation of fat reserves for hibernation. Hedgehogs also differed in behaviour associated with the risks posed by humans; they avoided actively foraging near roads and road verges, but did not avoid crossing roads per se. They were, however, significantly more active after midnight when there was a marked reduction in vehicle and foot traffic. In particular, responses to increased temperature, which is associated with increased abundance of invertebrate prey, were only observed after midnight. This variation in the timing of bouts of activity would reduce the risks associated with human activities. There were also profound differences in both area ranged and activity between years which warrant further investigation.