The fetus produces a stress response to painful stimuli from 18/40, but it is not proven if this is perceived as pain.
The nociception system is definitely known to be present and functioning from 26/40.
In practice we consider that any preterm baby can perceive pain and we should take steps to ameliorate it.
Reference: Rennie & Roberton’s Textbook of Neonatology, 5th Ed, 2005. London: Churchill.
Previously published: 16/10/14