Lac-Megantic _Quebec
A police officer looks at the remains of a demolished building in Lac-Megantic on July 14, 2013. Reuters/Mathieu Belanger

California and Texas will receive the biggest share of a $20 million grant from the Department of Transportation (DOT) plan to train and improve the nation’s response to hazardous materials transportation incidents, according to a statement by the DOT.

“Hazardous materials are transported throughout our nation every day, and most shipments arrive without incident,” said Anthony Foxx, secretary of the DOT in a statement last week. “But we have to be prepared for those rare instances when something goes wrong, and these grants do just that, by funding training and drills for our first responders so they can protect our families and communities.”

All 50 states receive grants, and Illinois, Ohio and New York all received the largest share of the $20 million.

Since 1993 more than 2.8 million emergency responders across the country have received training assistance using Hazardous Materials Emergency Preparedness grants.

The grants from the U.S. DOT’s Pipeline and Hazardous Materials Safety Administration (PHMSA) are funded by annual user fees paid by shippers and carriers of certain types of hazardous materials.

The announcement comes as the DOT’s Federal Railroad Administration issued an Emergency Order and Safety Advisory in August after the July 6, derailment in Lac-Mégantic, Quebec, Canada, to help prevent trains operating on mainline tracks or sidings from moving unintentionally.