OTTAWA—Canada and China have agreed to launch exploratory talks on a possible free-trade agreement, the leaders of both countries said Thursday.

Canadian Prime Minister Justin Trudeau and Chinese Premier Li Keqiang made the announcement in Ottawa, during Mr. Li’s trip to Canada.

Canada’s Liberal government, which came to power last fall,...