Many marine fish and invertebrates show a dual life history where settled adults produce dispersing larvae. The planktonic nature of the early larval stages suggests a passive dispersal model where ocean currents would quickly cause panmixis over large spatial scales and prevent isolation of populations, a prerequisite for speciation. However, high biodiversity and species abundance in coral reefs contradict this panmixis hypothesis. Although ocean currents are a major force in larval dispersal, recent studies show far greater retention than predicted by advection models. We investigated the role of animal behavior in retention and homing of coral reef fish larvae resulting in two important discoveries: ( i ) Settling larvae are capable of olfactory discrimination and prefer the odor of their home reef, thereby demonstrating to us that nearby reefs smell different. ( ii ) Whereas one species showed panmixis as predicted from our advection model, another species showed significant genetic population substructure suggestive of strong homing. Thus, the smell of reefs could allow larvae to choose currents that return them to reefs in general and natal reefs in particular. As a consequence, reef populations can develop genetic differences that might lead to reproductive isolation.