Sensitive periods, in which experience shapes phenotypic development to a larger extent than other periods, are widespread in nature. Despite a recent focus on neural-physiological explanation, few formal models have examined the evolutionary selection pressures that result in developmental mechanisms that produce sensitive periods. Here, we present such a model. We model development as a specialization process during which individuals incrementally adapt to local environmental conditions, while receiving a constant stream of cost-free, imperfect cues to the environmental state. We compute optimal developmental programmes across a range of ecological conditions and use these programmes to simulate developmental trajectories and obtain distributions of mature phenotypes. We highlight four main results. First, matching the empirical record, sensitive periods often result from experience or from a combination of age and experience, but rarely from age alone. Second, individual differences in sensitive periods emerge as a result of stochasticity in cues: individuals who obtain more consistent cue sets lose their plasticity at faster rates. Third, in some cases, experience shapes phenotypes only at a later life stage (lagged effects). Fourth, individuals might perseverate along developmental trajectories despite accumulating evidence suggesting the alternate trajectory is more likely to match the ecology.. . .we all begin with the natural equipment to live a thousand kinds of life but end in the end having lived only one.-Clifford Geertz, 1973