Prime Minister Narendra Modi headed home after ending his three-nation tour, with the final day spent in the city of Vancouver in British Columbia, visiting a temple and a gurudwara and attending an official dinner hosted by Canadian Prime Minister Stephen Harper.
In his final tweets before emplaning for India, Modi said: "I leave Canada with immense satisfaction. This visit will further enhance India-Canada ties. A big thanks to the people of Canada."
"A special thanks to @pmharper- a fine host, a wonderful human being and a very dear friend," he wrote on his twitter handle @narendramodi.
Besides visiting the two religious institutions connected with the diaspora, Modi also met British Colombia Premier Christy Clark.
The Canadian prime minister, who has been a constant companion of Modi throughout his Canadian tour, received him at Vancouver International Airport, and accompanied him to the Gurudwara Khalsa Diwan on Ross Street and the Laxmi Narayan temple in Vancouver.
Harper hosted an official dinner for Modi at the Pinnacle Vancouver Harbourfront Hotel.
At the Gurudwara, Modi and Harper had their heads covered in pieces of cloth in deference to the Sikh tradition not to enter bare headed.
Both were presented a yellow saropa, or a scarf of honour, and a sword each by the gurudwara authorities. Both the leaders stood with hands folded in prayer. Canada has 1.2 million Indian diaspora, with most concentrated in Vancouver.
Modi, in his address to the gathering at the gurudwara, spoke about the reconstruction of the gurudwara at Lakhpat in Gujarat during his tenure as chief minister.
He said the gurudwara at Lakhpat, where Guru Nanak had stayed for 15 days, had been damaged in the 2001 earthquake and had been reconstructed successfully.
Modi said: "We should fill life with colours of humanity and serve mankind."
Modi and Harper also visited the Komagata Maru Museum. The museum is in memory of the steamship of the name that reached Vancouver in 1914, carrying 376 passengers from Punjab, British India.
Of them 24 were admitted to Canada, but 352 other passengers were not allowed to land and the ship was forced to return to India.
At the Laxmi Narayan temple in Vancouver, Modi and Harper were presented with shawls and the priest put vermillion marks on their foreheads.
In his remarks at the temple, Modi thanked the Canadian prime minister and the people of Canada for the warm welcome and hospitality they had accorded him.
He said the Supreme Court of India had described Hinduism as a way of life.
He exhorted the gathering to live life scientifically, in balance with nature, and with compassion.
Modi said the United Nations recently adopted June 21 as the International Day of Yoga with 177 countries co-sponsoring India's resolution.
The prime minister said Yoga had great potential to help the world overcome the stress of modern life, and urged people to spread this message.
Modi visited France, Germany and Canada during his April 9-17 three-nation tour.