OTTAWA - Canada's Liberals put red-hot real estate markets squarely in their sights on Thursday, laying out a budget geared at boosting housing affordability amid soaring inflation, while promising modest new spending to encourage medium-term growth.

The 2022 budget set out C$9.5 billion ($7.5 billion) over five years in net new spending on housing initiatives and promised to legally ban foreigners from buying Canadian homes for two years, though it gave no timeline for that legislation.

It also pledged to target domestic housing speculators with new taxes, double new-home construction over the next decade and boost tax credits for first-time buyers. Most measures were outlined in the Liberal's re-election campaign last year.

"Our economy is built by people, and people need homes in which to live," Finance Minister Chrystia Freeland said as she presented the budget to lawmakers.

"We will invest in building more homes and in bringing down the barriers that keep them from being built," she continued. "We will prevent foreign investors from parking their money in Canada by buying up homes."

The budget also hiked corporate taxes for the country's most profitable banks and insurers to 16.5% from 15% on all taxable income over C$100 million, less than the 3% rise pledged in last year's election campaign. That, along with a one-time recovery dividend, will boost revenues by C$6.1 billion over the five-year budget time frame.

All told, the budget included a net C$29 billion in new spending over five years, as the waning COVID-19 pandemic allowed the government to ease off on emergency stimulus.

While that was less spending than some feared, economists said it would not help ease inflationary pressures.

"At the end of the day, we still are adding stimulus to the economy at a time when the Bank of Canada is actively trying to cool down inflation," said Robert Kavcic, senior economist at BMO Economics.

"I think it just reinforces what we're already expecting, which is pretty aggressive near-term tightening from the Bank of Canada," he added.

Inflation hit 5.7% in February and is expected to go higher before easing off later this year as supply chain bottlenecks unwind and the central bank increases interest rates.

The Bank of Canada hiked its policy rate to 0.5% in March and is widely expected to make a rare 50-basis-point increase next week.

The budget also offered a substantial incentive to companies investing in carbon-capture technologies and set aside as much as C$3.8 billion over eight years to accelerate critical mineral exploration, as Canada seeks to cut carbon emissions.

HOUSING AFFORDABILITY

Fast rising home prices - up 50.6% in two years - have become a political liability for politicians, as Canadians of all stripes struggle to find an affordable place to live.

While foreigners represent a small overall segment of home buyers in Canada, they can have an outsized impact on prices escalation and are an easy target for politicians, experts say.

Experts also questioned plans to double the pace of homebuilding over the next decade, noting that most supply measures would depend on other levels of government playing ball and a tight labor market for the skilled construction trades.

"I thought their housing chapter was weak, to be honest, a bit gimmicky," said Robert Asselin, senior vice-president for policy at the Business Council of Canada. "I'm not sure the federal government has any real levers here to influence supply."

Canada will also boost military spending by C$8 billion over five years and review its defense policy in the wake of the Russian invasion of Ukraine, while offering up to C$1 billion in new loan resources to Ukraine.

The budget deficit for the current fiscal year is nearly 10% lower than forecast in a December fiscal update, mostly due to higher revenues.

The federal debt-to-GDP ratio is now forecast to have peaked at 46.5% in 2021-22, down from 48.0% seen in December, before declining to 45.1% in the current year and then 44.5% in fiscal 2023-24.

($1 = 1.2600 Canadian dollars)

(Reporting by Julie Gordon and Steve Scherer in Ottawa; Editing by Aurora Ellis and Paul Simao)