TORONTO -- North American stock markets bounced back from Monday's losses as rising crude oil prices helped the energy sector while technology moved higher.

The rebound came as investors stepped in to buy the dip, said Candice Bangsund, portfolio manager for Fiera Capital.

鈥淭ech stocks recovered some ground in today's trading as investors stepped-in to pick up these shares at more attractive prices after the steep selloff over the last several weeks,鈥 she wrote in an email.

The sector moved positive on the TSX as Hut 8 Mining Corp. increased 7.2 per cent and Lightspeed Commerce Inc. was 1.7 per cent higher.

Bangsund said bond yields moved higher because of signs of economic strength in the U.S. that was signalled by the surprisingly positive ISM reading on the U.S. services sector in September. That will likely keep the Federal Reserve on track to scale back its asset purchases later this year.

The U.S. 10-year treasury yield surged higher to 1.53 per cent, just short of last week's peak of 1.56 per cent, while the Canada 10-year bond yield was only slightly behind.

Overall, gold stocks weighed on the Canadian market, which underperformed the S&P 500.

Materials rose 0.5 per cent even as the December gold contract was down US$6.70 at US$1,760.90 an ounce and the December copper contract was down 4.6 cents at US$4.19 a pound.

鈥淕old snapped a three-day winning streak as treasury yields edged higher after U.S. economic data bolstered optimism about the economic recovery, with higher interest rates dampening the appeal of non-interest bullion,鈥 said Bangsund.

Meanwhile, Canada's trade surplus more than doubled to $1.9 billion in August as exports of energy products climbed to their highest level since March 2014, Statistics Canada said.

The S&P/TSX composite index closed up 131.18 points to 20,183.43, the best performance in nearly two weeks and following Monday's loss of 98.62 points.

In New York, the Dow Jones industrial average was up 311.75 points at 34,314.67. The S&P 500 index was up 45.26 points at 4,345.72, while the Nasdaq composite was up 178.35 points at 14,433.83.

Energy was the best of all sectors but utilities that gained ground. It rose 2.8 per cent as Canadian energy producers climbed on rising crude and natural gas prices.

Vermilion Energy Corp. surged eight per cent while Tourmaline Oil Corp. rose 3.9 per cent and Suncor Energy Inc. was up 3.5 per cent.

The November crude contract was up US$1.31 at US$78.93 per barrel after reaching a high of US$79.48 in earlier trading and the November natural gas contract was up 54.6 cents at US$6.31 per mmBTU.

Crude oil prices are up nearly 63 per cent in 2021 while natural gas is 2.5 times higher.

The oil price rally continued after OPEC and its allies opted for only a modest increase to production of 400,000 barrels per day for November.

The Canadian dollar traded for 79.52 cents US compared with 79.47 cents US on Monday.

This report by The Canadian Press was first published Oct. 5, 2021.