Studies on resource polymorphism have mainly been considered at the end stage of ontogeny, whereas many species undergo diet changes as they grow. We conducted a field survey to analyze the role of adaptive variation during ontogeny in Eurasian perch (Perca fluviatilis). We caught perch from the littoral and pelagic zones of a lake to investigate whether perch differ in morphology and diet between these habitats. We also investigated whether there were any differences in morphological trajectories during the ontogeny of perch collected from the two habitats. We found that perch caught in the littoral habitat, independently of size, had a deeper body, larger head and mouth and longer fins than perch caught in the pelagic zone. Macroinvertebrates and fish dominated the diet of littoral perch, whereas the diet of the pelagic perch consisted mainly of zooplankton and to some extent fish. Independently of size, the more streamlined individuals had a larger proportion of zooplankton and a smaller proportion of macroinvertebrates in their diet than the deeper-bodied individuals, indicating a relation between diet and morphology. Some morphological characters followed different ontogenetic trajectories in the two habitats; e.g. the changes to a deeper body and a larger head were faster in the littoral than in the pelagic perch. The relationship between the length of perch and the size of the mouth and fins also differed between perch from the two habitats, where the increase in the length of the pelvic fin and the area of the mouth increased faster with size in the littoral perch. Our findings show that variation in morphology between habitats differs during ontogeny in a way that corresponds to functional expectations for fish species that occupy these habitats.