There is an association between gestation of a baby at delivery and the risk of special educational needs in later life.