The deadliest wreck killed 47 people in the town of Lac-Megantic, Quebec. Others have occurred in rural areas of North Dakota, Alabama, Oklahoma and New Brunswick. The derailments released almost 3 million gallons of oil, nearly twice as much as the largest pipeline spill in the U.S. since at least 1986.
"Safety is our top priority, and we have a shared responsibility to make sure crude oil is transported safely from origin to destination," U.S. Transportation Secretary Anthony Foxx said in a statement.
Under the agreement, railroads also would have to weigh the risks along particular routes and consider alternatives, although experts say it's inevitable the trains would continue going through population centers to reach certain destinations.
The railroads agreed to provide $5 million to develop a training curriculum for emergency responders tailored to crude accidents.
Transportation officials also have been working with the oil industry to make sure crude loaded onto trains is properly classified, so that responders know what they're dealing with when an accident or spill occurs.
Companies are required to determine the volatility of oil being shipped, but there are no mandated testing protocols, according to transportation officials.
(Read more: Another train carrying crude oil derails)
The North Dakota oil involved in July's Lac-Megantic accident had been misclassified as posing a minor danger.
Earlier this month, government investigators announced that 11 of 18 samples of oil being taken to rail loading stations in the Bakken region of North Dakota and Montana were misclassified. Hess Corp., Whiting Oil and Gas Corp., and Marathon Oil Co. face proposed fines of $93,000 for the alleged violations.
Since 2008, the number of tanker cars hauling oil has increased 40-fold, and federal records show that's been accompanied by a dramatic spike in accidental crude releases from tank cars.
While severity of recent accidents and their potential for even more serious consequences has raised safety concerns, transportation officials point out that over the past decade, derailments have decreased by 47 percent.
Hamberger of the railroad association said the commitments unveiled Friday underscore the high priority the industry has put on safely transporting crude. He suggested that compliance would not be a problem.
"Number one it's better for safety, and number two their reputation is on the line," he said.