The cars jumped the track about 2:30 a.m. CT.
Homes, businesses and a nursing home were evacuated in a one-mile radius after toxic fumes rose above the site.
Evacuees were told it could be 48 hours before they could return, said Lt. Craig Stansbury of the Lafayette Parish Sheriff's Office.
He said officers were going door to door ordering people to leave. A shelter was set up at Carencro High School.
Residents outside the evacuation area were advised to close windows and doors and turn off air conditioning to avoid any contamination.