TORONTO, April 30 (Reuters) - Canada's main stock index posted its biggest daily gain since the end of March on Thursday, with industrial and technology shares leading a broad-based move higher as stronger-than-expected corporate earnings outweighed uncertainty related to the war in the Middle East.

The Toronto Stock Exchange's S&P/TSX composite index ended up 645.94 points, or 1.9%, at 33,964.33, marking its highest closing level since April 20. For the month, the index was up 3.65%, recouping much of March's decline.

"The rally is a combination of a recovery from the selloff last month and improving sentiment about eventually the war will end at some point or there will be some sort of resolution, but I think more importantly it's earnings driven," said Stan Wong, a portfolio manager at Scotia Wealth Management.

"When earnings are rising the market can absorb a lot of the macro and geopolitical noise that's happening."

Iran said it would respond with "long and painful strikes" on U.S. positions if Washington renewed attacks, and also reasserted its control over the Strait of Hormuz, complicating U.S. plans for a coalition to reopen the waterway.

"Canada is a little bit of a different set-up (than the U.S. market) - it's more cyclical, as we know, and right now it's working," Wong said.

Canada's economy grew by 0.2% in February from January, while a preliminary estimate pointed to annualized growth of 1.7% for the first quarter, which would slightly eclipse the Bank of Canada's 1.5% forecast.

Industrials rose 2.4%, with shares of Bombardier Inc jumping 20.6% after the business jet maker beat Wall Street estimates for first-quarter profit.

Technology added 2.2% and heavily weighted financials ended 2.1% higher.

The materials group, which includes metal mining shares, was up 1.4% as a sharp decline for the U.S. dollar gave gold and copper prices a boost.

Energy added 0.8%. The price of oil touched a three-week high before settling 1.7% lower at $105.07 a barrel.

(Reporting by Fergal Smith in Toronto and Tharuniyaa Lakshmi in Bengaluru; Editing by Joyjeet Das and Chris Reese)

By Fergal Smith