Justin Trudeau is set to become Canada's new prime minister after his Liberal Party surged ahead of the incumbent party, ending nearly a decade of Conservative Party rule.

The 43-year-old Trudeau - the eldest son of Pierre Trudeau, considered the father of modern Canada, led his party's stunning electoral performance in a federal election on Monday.

Canada's major television networks projected a majority for the Liberals, ending the Conservatives' nine-year run in power and reflected a political shift away from the incumbent Prime Minister Stephen Harper's brand of fiscal and cultural conservatism.

While the final vote count was not yet complete, Trudeau's Liberals were on track to win 174 of Parliament's 338 seats, according to Elections Canada.

Early results on Monday showed the Liberals swept all 32 seats in the country's Atlantic Provinces, doubling their popular support in the region, and scored well in key Ontario and Quebec provinces.

Trudeau is on track to break the record for the biggest gain in seats in an election, which was previously held by the Conservatives, who added 111 seats in the 1984 election. It is the largest percentage increase in seats ever gained by a party in an election.

The governing Conservatives held 13 of Atlantic Canada's 32 seats and the New Democratic Party held six when the election was called.

"A sea of change here. We are used to high tides in Atlantic Canada. This is not what we hoped for," said Peter MacKay, a former senior Conservative cabinet minister.

The 11-week campaign was considered too close to call for nearly two months, a virtual tie between the Conservatives, Liberals and left-leaning NDP.

Trudeau, who took over a party in shambles in 2013, trailed early in the campaign, brushed off by his opponents as being more style than substance and an intellectual lightweight who was not ready for the job.

But a bold pledge to run a budget deficit and boost spending to spur the economy, as well as a positive message and his gregarious nature, helped the Liberals engineer a turnaround.

Up to 26.4 million electorates were eligible to vote in 338 electoral districts. About 3.6 million had already cast a ballot in advance voting a week ago.

Amid the issues raised during the campaign was a record influx of refugees fleeing war in Syria, a court ruling quashing a veil ban and a recession - crises that gave Canadians a chance to assess parties' reactions in near-real time.