Ministers have also unveiled a £255m fund to help councils tackle emissions, including the potential for charging zones for the dirtiest vehicles.
But the £3bn clean air strategy does not include a scrappage scheme, calling previous ones “poor value” for money.
Local government leaders welcomed the funding but called for more detail.
- Reality Check: Does pollution cut short 40,000 lives a year?
- Questions about the petrol and diesel car ban
- Special Report: So I can breathe
Local authorities will be given direct financial support from the government, with £40m of the fund being made immediately.
They can use the funds for a range of measures, such as changing road layouts, implementing new technologies or encouraging residents on to public transport.
If those measures do not cut emissions enough, charging zones could be the next step – but the government says these should only be used for “limited periods”.
The timetable for councils to come up with initial plans has been cut from 18 months to eight, with the Department for Environment, Farming and Rural Affairs (Defra) wanting to “inject additional urgency” into the process.
It follows the government being given its own deadline of 31 July after High Court judges said it was failing to meet EU pollution limits.
Other points include:
- The funding pot will come from changes to tax on diesel vehicles and reprioritising departmental budgets – the exact details will be announced later in the year.
- Councils could change road layouts, retrofit public transport, and encourage local people to leave their cars at home.
- A Clean Air Fund would allow local authorities to bid for additional money to put in more air quality control measures.
- A new Automated and Electric Vehicles Bill will allow the government to require the installation of charge points for electric vehicles at motorway service areas and large fuel retailers.
Local Government Association environment spokesman Martin Tett said the plans to allow councils to switch their focus from monitoring air quality to improving air quality was the right move and welcomed the additional funding.
However, he opposed the view of the government to hold off on a scrappage scheme, arguing “this immediate intervention could help increase the uptake of lower emission vehicles”.
Ministers have been wary of being seen to “punish” drivers of diesel cars, who, they argue, bought the vehicles after being encouraged to by the last Labour government because they produced lower carbon emissions.
The industry trade body, the Society of Motor Manufacturers and Traders, said it was important to avoid outright bans on diesels, which would hurt the sector.
SMMT chief executive Mike Hawes said demand for alternatively fuelled vehicles was growing but still at a very low level.
“The industry instead wants a positive approach which gives consumers incentives to purchase these cars. We could undermine the UK’s successful automotive sector if we don’t allow enough time for the industry to adjust.”
The AA said significant investment would be needed to install charging points across the country and warned the National Grid would come under pressure with a mass switch-on of recharging after the rush hour.
The UK announcement comes amid signs of an accelerating shift towards electric cars instead of petrol and diesel ones, at home and abroad:
- Earlier this month, President Emmanuel Macron announced similar plans to phase out diesel and petrol cars in France, also from 2040.
- BMW announced on Tuesday that a fully electric version of the Mini would be built at the Cowley plant in Oxford from 2019.
By Roger Harrabin, BBC environment analyst
So how will the air be cleaned up? Plans for a diesel scrappage scheme for old vehicles have been rejected by the Treasury as poor value for money. They may be reconsidered in the autumn.
The government has told councils to solve pollution on their own streets by improving public transport and considering restrictions on dirty diesel vehicles at peak times.
If that doesn’t work, councils will be told to charge diesel drivers to come into towns.
The councils aren’t happy to take the rap for the controversial policy when it was the government that encouraged the sale of diesel vehicles in the first place.
Today’s government plan is not comprehensive – it doesn’t address pollution from construction, farming and gas boilers.
And clean air campaigners say the government is using the 2040 electric cars announcement to distract from failings in its short-term pollution policy.
Air pollution is thought to be linked to about 40,000 premature deaths a year in the UK, and transport also contributes to greenhouse gas emissions.
A government spokesman said poor air quality was “the biggest environmental risk” to public health in the UK.
The measures are “good” in the long term but “not very effective” in the short, industry expert David Bailey said.
A switch-over to electric cars would likely come in the mid-2020s, he predicted, when electric cars would out-compete petrol and diesel ones on factors like cost.
“This sets a very clear direction of travel, but petrol and diesel cars won’t exist by 2040,” he said.
He said more incentives were needed now, otherwise urban air quality would not improve.
Environmental law firm ClientEarth welcomed the measures, but said it wanted to see more detail.
Chief executive James Thornton said the law found ministers must bring down illegal levels of air pollution as soon as possible.
Green Party MP Caroline Lucas welcomed a ban but said it did not go “nearly far enough or fast enough”.
Friends of the Earth said the plan was a “cynical” move which passed the buck of saving lives to local authorities.
Labour said the government was only acting after being taken to court.
Environment, Food and Rural Affairs spokeswoman Sue Hayman MP said the government had a “squeamish” attitude to clear air zones, and was shunting the problem on to local authorities.
“With nearly 40 million people living in areas with illegal levels of air pollution, action is needed now, not in 23 years’ time,” she said.