A freight train travelling from the West Coast to Christchurch struck around 20 cattle, just before midnight.
"Incidents like this are obviously catastrophic for the animals and distressing for farmers, our train drivers and those who need to clear the rail line.
"Sadly, events like these are not unusual and last night's incident is a timely reminder of the need to keep land well-fenced and gates closed to prevent livestock getting on the tracks," KiwiRail's South Island operations manager Mark Heissenbuttel said.
"The best prevention is for farmers to ensure their stock are contained along their boundaries with the rail corridor."
A police spokeswoman confirmed they are aware of the incident and trains on the line were stopped until 2am when they were cleared.
Ten to 12 of the animals were euthanised at the scene, the spokeswoman said.