British Transport Police were called to the line in Moorends, near Doncaster, at 6.13pm yesterday following reports of a casualty on the tracks.
It is understood emergency crews attended at the level crossing in Marshland Road following the incident which closed the railway line between Doncaster and Hull for several hours.
Bus strike Sheffield: Seven day Stagecoach strike to start on Sunday confirms Unite union
Family members and friends have posted on social media that the victim of the tragedy was a young boy.
A spokesman for British Transport Police said: “Officers were called to the line in Moorends at 6.13pm yesterday following reports of a casualty on the tracks.
"Paramedics also attended. However, sadly a male was pronounced dead at the scene.
“This incident is not being treated as suspicious and a file will be prepared for the coroner.”
Rail operator Northern said trains had been diverted as a result of the tragedy.