Environmentalists, religious groups and others have cheered the mine closings, saying that corruption has long given the mining industry free rein to pollute. Among the supporters is the country’s popular president, Rodrigo Duterte.

“Sons of whores, look at what you’re doing,” Mr. Duterte said last month, addressing the mining companies. He has dismissed concerns about the potential loss of tax revenue from closed mines, saying, “We can live without it.”

Image “It is time for social justice,” said Gina Lopez, the acting secretary of the environment. “You cannot run your business and affect our farmers and fishermen.” Credit... Romeo Ranoco/Reuters

The costs are substantial. The government has estimated that 234,000 jobs could be lost. The mining industry says the closings would affect as many as 1.2 million people, including employees of companies that depend on the industry, like equipment suppliers.

The country’s annual nickel ore production would fall as much as 50 percent, Ms. Lopez has said. Such a drop, analysts said, would dent global supply by 8 percent to 10 percent. A temporary increase in world nickel prices followed Ms. Lopez’s announcement in February.

Many mines continue to operate while companies fight Ms. Lopez’s orders in court. They are also opposing her permanent appointment as environment secretary, which Congress is expected to vote on next week. (In the Philippines, presidential appointees can run departments before they are confirmed, but they must step down if Congress votes against them.)

Ms. Lopez, a former environmental activist, said that her office was rushing to finalize the ban on open-pit mines before the confirmation hearing. “I am not going to take the risk of not getting it done,” she said in an interview on Thursday.