The announcement comes after months of pressure on Justin Trudeau's Liberals to launch a full inquiry amid claims of meddling by China.
It will look at allegations of interference by China, Russia and other foreign actors.
The claims have strained relations between Canada and China.
Federal Public Safety Minister Dominic LeBlanc announced on Thursday that Justice Marie-Josée Hogue, from the Quebec Court of Appeal, will lead the inquiry.
Ms Hogue will look into potential interference not only from China, but from Russia and other foreign and non-state actors as well. She will investigate the impacts on election integrity at the national and electoral level during the 2019 and 2021 elections.
Asked why the scope has been broadened to not just look at China, Mr LeBlanc said that it's "not the only foreign actor that seeks to undermine Canada".
Thursday's announcement ends a months-long search for an official to lead a public inquiry after former Governor General David Johnston, who was appointed to investigate claims of election interference, resigned from his role earlier this summer following accusations he was biased towards the Liberals.
He cited the "highly partisan atmosphere" around his appointment as his reason for quitting.
Allegations of foreign interference stem from reports, mostly based on leaked intelligence, in Canadian media in recent months that detailed claims of Chinese meddling in the country's last two federal elections. China has denied any interference.
Any meddling was not believed to have changed the outcome of either campaign, but Mr Trudeau's government has faced claims that it ignored warnings from officials.
Mr LeBlanc said Justice Hogue was named with the support of all the opposition parties.
"Justice Hogue will have full access to all relevant cabinet documents, as well as all other information she deems relevant for the purposes of her inquiry," he said.
In May, China expelled Canada's consul in Shanghai in retaliation for Ottawa sending home a Chinese diplomat accused of trying to intimidate a Canadian member of parliament who had criticised China on human rights.
In an interview with Bloomberg on a tour to Asia, Mr Trudeau on Thursday addressed the Canada-China tensions, calling the current bilateral relationship "stable" but acknowledging "a challenging few years".
"But China is one of the most important economies in the world and it's not a country that anyone can simply ignore," he told Bloomberg.
Ms Hogue was appointed to the Quebec Court of Appeal on 19 June 2015. During her time as a partner at a law firm, her main areas of practice were corporate commercial litigation, civil litigation and professional liability, according to the court website.