President Asif Ali Zardari ordered the release of Gopal Das late last month after an appeal from India's Supreme Court.
Das was handed over to Indian authorities at the Wagah border crossing, confirmed Mehboob Hussain, spokesman for the paramilitary rangers at Wagah.
"Das was more than happy. His family members also came to receive him," said Mohammad Sajid, a paramilitary official.
Das -- who told reporters he was 26 when he was arrested -- was sentenced to life in prison in June 1987 and had been due for release by the end of this year.
Pakistan's presidency did not say why he was convicted, but a senior official in Lahore's Kot Lakhpat prison, where he was held, said last month that Das had been jailed on spying charges.
His release was ordered after Indian Prime Minister Manmohan Singh invited the Pakistani president and prime minister to watch last week's cricket World Cup semi-final between the two countries in Mohali, India.
Prime Minister Yousuf Raza Gilani accepted the invitation and became the most senior Pakistani leader to visit India since 2001 in what was quickly dubbed "cricket diplomacy" as tensions eased slightly between the two rivals.
Hundreds of Indians and Pakistanis are languishing in prisons on both sides of the border on charges of spying or illegal entry.
The 2008 Mumbai attacks torpedoed a four-year peace process after India blamed the carnage on Pakistan-based militants.
Visiting British Prime Minister David Cameron this week urged Pakistan and India to move closer, describing the sight of Gilani and Singh sitting together to watch the match as a "tremendous sign of hope for the future".