(Adds details throughout, updates prices to close)

* TSX ends down 187.59 points, or 0.95%, at 19,505.33

* Canadian factory activity loses further momentum in July

* Materials sector falls 2.3%

* Shopify rallies 8.9%

TORONTO, Aug 2 (Reuters) - Canada's main stock index fell on Tuesday, giving back some recent gains, as a slowdown in manufacturing activity as well as rising tensions between the United States and China dented investor sentiment.

The Toronto Stock Exchange's S&P/TSX composite index closed down 187.59 points, or 0.95%, at 19,505.33, as trading resumed following a market holiday on Monday.

On Friday, the index notched its highest closing level in nearly seven weeks.

Wall Street also fell on Tuesday as U.S. House of Representatives Speaker Nancy Pelosi visited Taiwan, in a move that was condemned by China.

Meanwhile, data showed that Canadian manufacturing activity lost further momentum in July as production and new orders declined for the first time since the early stages of the coronavirus pandemic.

"Businesses have right now shrunk down with rising labor costs and higher interest rates," said Allan Small, senior investment advisor at Allan Small Financial Group. "You can't keep expanding, you can't keep hiring and you can't keep growing the business when conditions are not favorable."

The materials sector fell 2.3%, pressured by a decline in copper and gold prices, while energy ended nearly 2% lower.

Heavily-weighted financials fell 0.8%, with Toronto Dominion Bank down 0.4% after it said it will buy New York-based boutique investment bank Cowen Inc for $1.3 billion in cash.

In contrast, shares of e-commerce giant Shopify Inc rallied 8.9%, adding their recent rebound. (Additional reporting by Bansari Mayur Kamdar and Johann M. Cherian in Bengaluru Editing by Marguerita Choy)