OTTAWA -- A surge in gasoline prices helped drive Canada's annual inflation rate well beyond expectations in January to 2.1 per cent -- an increase that coincided with the implementation of new carbon-pricing policies in Ontario and Alberta.

Statistics Canada said Friday the 6.3 per cent increase in transportation costs was the main contributor to the higher inflation rate, with gas prices spiking by 20.6 per cent across the country compared to the year before.

The overall inflation reading last month was stronger than December's rate of 1.5 per cent, the agency's latest consumer price index said. However, excluding gasoline, the January inflation rate was also 1.5 per cent.

BMO chief economist Douglas Porter said the dramatic jump in pump prices was a combination of the underlying strength in oil prices and the new carbon levies that came into effect last month in both Ontario and Alberta.

"That was the big story as to why overall inflation is now back above two per cent for the first time in a couple of years," Porter said.

In Alberta, the annual inflation rate hit 2.5 per cent last month after an increase of one per cent in December. Gas prices in Alberta soared 33.9 per cent last month, a gain that Statistics Canada says was partly attributable to a new carbon levy in the province.

The agency said Ontario, which introduced a cap-and-trade program in January, saw a 20.4 per cent year-over-year increase in gas prices last month.

TD senior economist James Marple wrote in a note to clients that, when it comes to inflation, the influence of the carbon levies will be a factor to watch going forward. He doesn't expect the carbon-levy increases to fall out of future data releases.

"Over time, substitution away from energy products should reduce the impact of gains in energy prices on inflation, but this will take time to show up," he wrote.

The Ontario energy minister's office said in an email that the province still has lower gas prices than most provinces and that fluctuating global crude prices are the biggest factor in determining what people pay at the pump.

Statistics Canada also found that year-over-year inflation rates were higher in every province last month compared to a year earlier.

Overall, a consensus of economists had predicted 1.6 per cent inflation for January, according to Thomson Reuters.

Statistics Canada says consumers paid four per cent less at grocery stores last month compared to a year earlier.

The agency said the Bank of Canada's three preferred measures for core inflation saw increases last month of 1.3 per cent, 1.7 per cent and 1.9 per cent.

Here's what happened in the provinces and territories (previous month in brackets):

Newfoundland and Labrador: 4.7 per cent (4.1)

Prince Edward Island: 2.5 (1.3)

Nova Scotia: 1.8 (1.3)

New Brunswick: 3.3 (2.3)

Quebec: 1.3 (0.6)

Ontario: 2.3 (2.0)

Manitoba: 2.1 (1.1)

Saskatchewan: 1.6 (0.6)

Alberta: 2.5 (1.0)

British Columbia: 2.3 (1.9)

Whitehorse, Yukon: 2.3 (1.6)

Yellowknife, N.W.T.: 2.2 (1.0)

The agency also released rates for major cities, but cautioned that figures may have fluctuated widely because they are based on small statistical samples (previous month in brackets):