Canada's trade surplus shrank more than expected in July as imports rose because of the stronger Canadian dollar, while the housing sector proved surprisingly resilient this summer, figures released on Tuesday showed.

Analysts said the trade report combined with solid numbers for housing starts in August and new housing prices in July highlighted a contrast between robust domestic demand and weakening exports.

The figures are not expected to alter the Bank of Canada's resolve to hold interest rates steady.

Even though the strong domestic economy and persistent upward pressure on housing prices would normally see the Bank of Canada tighten monetary policy, we expect that the volatility in financial markets and increased downside risks to the U.S. economic outlook will keep the bank on the sidelines for now, said Paul Ferley, assistant chief economist at Royal Bank of Canada.

The July trade surplus narrowed to C$3.66 billion ($3.49 billion) from a downwardly revised C$4.33 billion in June as imports grew twice as fast as exports and soared to a record high, Statistics Canada said.

A stronger currency increases the purchasing power of Canadian companies in foreign countries.

Analysts surveyed by Reuters had expected the surplus to narrow to C$5.0 billion from the original June amount of C$5.27 billion.

On balance, this is not a great report, but it doesn't necessarily signal softness ahead ...strength in Canadian imports is a testament to the resilience of the Canadian economy, said Charmaine Buskas, senior economist at TD Securities.

The trade sector will likely continue to drag in the months ahead but strong consumer and business spending will mean the economy will continue to grow at a healthy pace, Ferley said. The economy expanded 3.4 percent in the second quarter and 3.9 percent in the first.

July imports rose 3.5 percent to C$35.67 billion, getting a boost from a 14.1 percent jump in automotive products imports and a 2.8 percent increase in imports of machinery and equipment.

Exports rose 1.4 percent to C$39.32 billion as shipments of industrial goods and materials hit a record high of C$9.7 billion, up 6.6 percent on the month.

Canada's trade surplus with its top market, the United States, narrowed to its smallest since October 2006, while its surplus with other countries grew.

That could be a signal for the Bank of Canada as it watches for signs that the weakness in the U.S. economy and the global credit squeeze may be spilling over into Canada.

The bank held its key overnight lending rate steady at 4.50 percent on Sept. 5, citing the risk to growth from recent turmoil in financial markets.

There were no signs Canada's housing market is suffering.

A report by Canada Mortgage and Housing Corp. showed Canadian housing starts rose 5 percent in August to a seasonally adjusted annualized rate of 226,500 units from 215,600 units in July. The number of starts beat the consensus expectation of analysts for 220,000 starts.

In July, the price of new homes rose 0.9 percent from June. But the year-on-year price increase slowed for the 11th straight month to 7.7 percent, Statistics Canada said. Analysts had called for a 0.6 percent rise in July.

In contrast to its U.S. counterpart, Canadian residential investment continues to add to GDP growth as the housing sector remains in very good shape, though we expect some moderation in the sector for the remainder of the year, said Karen Cordes, economist at Scotia Capital.