Jason Kenney delivered a rousing and emotional farewell speech in the House of Commons on Thursday after nearly 20 years as a member of Parliament.

He struck a non-partisan tone and urged his colleagues to embrace their role as legislators, not simply as foot soldiers of a political party, and to relish their time in the hallowed halls of Centre Block — "the temple of our democracy," as he described it.

"When I arrived here as a young, 29-year-old rookie MP in 1997 I was filled with a sense of idealism, optimism and hope and a determination not to sacrifice my core convictions. I hope and believe that today I am still filled with the same idealism and motivated by the same convictions," Kenney said.

He jokingly thanked his "long-suffering constituents" for sending him to Ottawa seven times, and invoked memories of his grandfather, a lifelong member of the Liberal Party, and a celebrated musician, who inspired his interest in politics.

"I appeal to my colleagues from all partisan traditions, first and foremost, to respect this institution and this chamber as a place of deliberation. Now, Mr. Speaker, if I have not lived up to those standards, I apologize," he said. "I hope we can renew, I hope you can renew, the best traditions of this place."

Kenney is feted by MPs on all sides of the House 2:27

Kenney spent roughly half his time as an MP in government, and the other half in opposition, a position he said made him uniquely qualified to offer advice to members on both sides of the House.

He said the opposition parties should have a greater degree of "understanding and patience" with those in government, and Liberal MPs should be more accepting of tough questions lobbed at them from the benches opposite.

'Smiling Buddha'

He also delivered a passionate defence of Canada, and put his patriotism on display.

"Canada is made up of people who are on the wrong side of history," Kenney said, listing First Nations, French-Canadians after the conquest, the Acadians, United Empire Loyalists fleeing the American Revolutionary War, escaped black slaves, Highland-cleared Scots and famished Irish immigrants along with modern-day refugees: Syrians, Iraqis and gay Iranians.

"All of them in their own way are losers of history and yet, by becoming Canadian, they have become winners of history," he said.

The Calgary–Midnapore MP also reflected on his time as minister of immigration — Canada's longest-serving — and his efforts to court immigrants, and bring them into the Conservative fold.

He was a staple in Chinese banquet halls and Sikh temples across the country and lifted Tory turnout in communities that were typically, loyally Liberal. (He was nicknamed the 'Smiling Buddha' by members of the Chinese-Canadian community.)

"I have never believed, as a 10-year minister of multiculturalism, that it is adequate simply to celebrate our diversity. I think we must aspire to unity in our diversity."

Jason Kenney is running for the leadership of Alberta's Progressive Conservative Party, and hopes to unite it with the Wildrose Party to take on Premier Rachel Notley's NDP. (Jeff McIntosh/Canadian Press)

Kenney said while he is leaving federal politics he is hopeful for the future of his party, and trusts it can recover from its stinging defeat last October.

"This is a party that has gone through a difficult election in recent months. But has emerged with great strength and confidence thanks in no small part to the brilliant leadership of the honourable leader of the opposition," he said, with a nod to interim leader Rona Ambrose.

Ambrose was equally celebratory of her former cabinet colleague.

"It's no exaggeration to say that he is regarded by all of us on this side of the House as an elder and a mentor, although he is still pretty young. But he has seven years on me as an MP, but that goes without saying, Mr. Speaker, because he is much older than me," she said to laughs.

She commended his hard work — telling her fellow MPs that Kenney routinely kept 20 hour days as a cabinet minister — and leadership on the immigration file.

Kenney's last day on Parliament Hill is Friday before he sets out for Alberta to run for leadership of the Progressive Conservative Association of Alberta. He hopes to unite the PCs with the opposition Wildrose Party to topple Alberta's NDP government in the next election.