President Biden last week signed an executive order tasking the government with reaching net-zero greenhouse gas emissions by 2050, leveraging federal procurement to help build the market for greener products. Mr. Biden’s action sounds more impressive than it is. Any executive order he issues might not survive beyond his presidency. Until Congress finally writes into law a comprehensive climate policy that provides a road map for a decades-long transition off polluting energy, the nation’s response to global warming will be fatally insufficient.

The president directed federal agencies to source all their electricity from carbon-free renewables or nuclear by 2030. He called for the federal government to stop purchasing gas-powered passenger cars by 2027 and to buy only zero-emission vehicles for its fleet of 600,000 by 2035. And Mr. Biden ordered an overhaul of the federal government’s roughly 300,000 buildings; heating, cooling and powering energy-hungry buildings is an underappreciated source of waste.

These are not small commitments. For comparison, the federal government bought only 650 electric vehicles last fiscal year — of the roughly 50,000 vehicles it typically purchases annually. Boosters of the plan argue that government demand will spur development of the electric car and battery industry, which still sells relatively few vehicles. Fighting climate change is a war of increments; like every other major entity in the United States, the federal government will have to wean itself off polluting energy in the coming decades, and it should lead by example.

But there are limits to what Mr. Biden can promise with his pen alone. The federal government is responsible for only about 1.5 percent of the nation’s energy consumption. Some 17 million cars, trucks and SUVs are sold in the United States every year, dwarfing the federal fleet. It might be harder than expected to replace all the federal government’s vehicles with cleaner ones or to rebuild special-purpose buildings. Even then, Congress will have to allocate money over the course of decades to see through the transition Mr. Biden has mapped out. And that assumes future presidents stick to Mr. Biden’s plan, which they almost certainly will not. President Donald Trump canceled a similar executive order that President Barack Obama issued.

Only Congress has the power to shift the whole country onto cleaner energy. Democrats seek to pass a sweeping, nearly $2 trillion social spending and climate package. The version that the House approved last month contained some $500 billion for global warming initiatives, including a $320 billion tax credit program that would drive renewables deployment. Sen. Joe Manchin III (D-W.Va.) has signaled skepticism about pieces of the plan, such as a fee on emissions of methane, a highly potent greenhouse gas. In fact, Senate Democrats should aim to make the policy more, rather than less, ambitious. Instead of merely subsidizing clean energy, they should put a stiff and rising tax on carbon-intensive fuels, then reinvest the proceeds into energy research, efficiency initiatives and rebates to consumers.

Failing to pass a substantial climate bill is not an option. The moment demands the best policy the nation can advance. Mr. Biden’s climate legacy will be determined in the coming weeks not in the Oval Office but on the Senate floor.