Environmental officials in Colorado are working to clean up one million gallons of wastewater containing heavy metals that spilled from an abandoned mine, turning an adjoining river a murky, mustard shade of yellow.

The Environmental Protection Agency caused the spill on Wednesday while it was investigating a leak at the Gold King Mine. The wastewater flowed into Cement Creek, a tributary of the Animas River in southwestern Colorado, and snaked through the river toward New Mexico.

E.P.A. officials confirmed the leak contained heavy metals, including lead and arsenic, but said it was too early to know whether there was a health risk to humans or animals. The river was closed for recreational and other uses, but officials said water sources should be safe.

“The orange color is alarming to people, but that is not an indication in any way of a health risk,” said Joan Card, an official with Region 8 of the E.P.A. Testing is ongoing, she said.