For investors in Canadian stocks, a set of six earnings releases issued between Aug. 23 and Aug. 31 could very well have been the most important event of 2017.

Those were the earnings releases from the Big Six Canadian banks, for their fiscal third-quarter ended on July 31. The results were good, investors took notice and the bank stocks have been rallying ever since. As 2017 draws to a close, shares of each of them are trading at or near all-time highs.

It was a stark shift in sentiment compared to the first nine months of the year, when worries about bank stock valuations and a worrisome Canadian real estate market kept the stocks well below the levels at which they began the year.

In their third quarter, each of the banks topped profit expectations, making it plain that investors had grown too pessimistic about the ability of the banks to drive profits higher in a slow-growth Canadian economy.

The strength was consistent, and it ran deeply through each of the quarterly reports.

Credit quality either improved or was “benign”, meaning loan losses were no longer eating into profit. A case in point was Toronto-Dominion Bank (TD.TO), which saw credit quality improve in both its Canadian and U.S. operations.

Most of the banks reported strong profit growth in their core Canadian retail banking businesses during the fiscal third quarter. National Bank of Canada (NA.TO) led the pack with 21 per cent growth in its domestic banking business, benefitting from a heavy exposure to the booming Quebec economy. Not far behind were TD and Bank of Nova Scotia (BNS.TO), where domestic banking profit rose 14 and 12 per cent, respectively.

And, with one exception, the numbers were good in non-Canadian markets as well. TD’s big retail banking network in the northeastern United States boosted profit by 11 per cent, and Scotia’s international segment reported a 16 per cent lift in profit. The exception was Bank of Montreal (BMO.TO), which reported a flat quarter in the U.S. 

It was numbers like those that sparked a wave of buying in Canadian bank stocks that has persisted into the end of the year. Indeed, the S&P/TSX Banks sub-index is up ten percent since the day the final fiscal third-quarter earnings report was released.

As we head into 2018, attention remains focused on Canada’s residential real estate market. If the banks face a threat to their robust pace of profit growth, it lies in their mortgage portfolios – which make up between 30 and 60 per cent of their overall lending portfolios. A significant slowdown in housing activity would mean slower growth in the mortgage books.

Ottawa – and the governments of British Columbia and Ontario – have taken numerous steps to cool down housing markets. The results have been mixed so far, but more change is coming in 2018. The federal banking regulator has approved new, more stringent guidelines on underwriting mortgages and those new rules – dubbed the B-20 guideline - go into effect on Jan. 1.

Analysts expect those rules to dampen growth in the residential mortgage market – but say the big banks are already largely “on side” with the new rules, suggesting the Big Six should be able to maintain their overwhelming share of the mortgage market.  And with Canada’s economy growing and its unemployment rate falling, most experts don’t anticipate a material drop-off in housing activity in 2018.