Canadian Prime Minister Justin Trudeau has called a federal election for 21 October.

Opinion polls are indicating it will be a tough race for Mr Trudeau, who is seeking a second term in office.

The campaign is expected to focus on issues of affordability, the economy and climate issues.

The prime minister visited the Governor General, Canada's acting head of state, on Wednesday morning to formally launch the campaign.

Mr Trudeau touted his accomplishments in an announcement, saying: "Canadians get to vote once again for the country they want to live in".

Canada has a federal fixed election date and Canadians must head to the polls every four years. This campaign will be a relatively short 40 days, or just over five weeks.

Over the summer, the rival parties have been honing their message, focusing on the economy and cost-of-living.

Climate change is also an important issue to voters, according to opinion polls.

Mr Trudeau will have to defend his record, including his handling this year of an ethics crisis that proved politically costly.

The prime minister was found by a federal ethics watchdog to have improperly tried to influence a former minister over the prosecution of SNC-Lavalin, a major engineering and construction company facing a criminal trial.

The campaign is currently shaping up to be a battle between two parties: the Liberals and the Conservatives.

National polls indicate they are in a dead heat, with both on just over 30% support.

The NDP are polling nationally in third place, on roughly 13%-14% support, with a slight lead over the Green Party.

Who's in the running?
Mr Trudeau was an untested leader in 2015 when he won a majority government. Now, it's his turn to face opponents who are unproven campaigners.

His main rival is the Conservative Party's Andrew Scheer.

Mr Scheer, 40, formerly the youngest-ever speaker in Canada's House of Commons, took the helm of the right-leaning party in 2017.

Another fresh face in federal politics is Jagmeet Singh, 40.

The leader of the left-leaning New Democrats (NDP), he is the first person of colour to have taken the helm of a major federal political party in Canada.

The separatist Bloc Quebecois, under new leader Yves-Francois Blanchet, will be competing for seats against the Liberals, Conservatives and the NDP in Quebec, a crucial battleground province in federal politics.

The Bloc only runs candidates in that province.

The Green Party, led by Elizabeth May, will be focusing efforts on trying to break through in British Columbia and Atlantic Canada.