President Pranab Mukherjee rejected a mercy petition from Mohammad Afzal Guru and he was hanged at 8 a.m. (0230 GMT) in Tihar jail in the capital, New Delhi. Security forces anticipating unrest had imposed a curfew in parts of insurgency-torn Kashmir and ordered people off the streets.
Guru, from the Indian part of divided Kashmir, was convicted of helping organise arms for the gunmen who made the attack and a place for them to stay. He always maintained his innocence.
India blamed the attack on the parliament of the world's largest democracy on militants backed by Pakistan, targeting the prime minister, interior minister and legislators in one of the country's worst ever militant attacks.
Pakistan denied any involvement and condemned the attack but tension rose sharply and brought the nuclear-armed rivals dangerously close to their fourth war. Nearly a million soldiers were mobilised on both sides of the border and fears of war only dissipated months later, in June 2002.
The hanging was ordered less than three months after India executed the lone surviving gunman of a 2008 attack in the city of Mumbai in which 166 people were killed.
Saturday's execution could help the ruling Congress party deflect opposition criticism of being soft on militancy as it gears up for a series of state elections this year and a general election due by 2014, while grappling with an economic slowdown.
"Congress has decided to be more proactive in view of the elections, not only in terms of economic policy but also matters like the hanging," said political analyst Amulya Ganguli.
"The Congress has now deprived the BJP of a propaganda plank," he said, referring to the main opposition Bharatiya Janata Party.
Government officials dismissed suggestions that electoral politics played a role in the decision to execute Guru.
In major towns of Indian Kashmir, where security forces have battled a Muslim separatist insurgency for decades, barricades were erected and hundreds of police and paramilitary force members were deployed.
"The hanging of Afzal Guru is a declaration of war by India," said Hilal Ahmad War, leader of a separatist faction.
Thirty-six people including 23 policemen were injured in protests, said police spokesman Manoj Sheeri, with most of the violence in Guru's home district.
Authorities shut down internet services to try to stop news of the hanging and unrest spreading. The chief minister of Jammu and Kashmir state, Omar Abdullah, made a televised appeal for calm.
Scuffles also broke out in New Delhi between Hindu activists and demonstrators who gathered at a city-centre protest site to condemn the execution, a Reuters witness said.
Five militants stormed the parliament complex in New Delhi on Dec. 13, 2001, armed with grenades, guns and explosives, but security forces killed them before they could enter the main chamber. Ten other people, most of them security officers, were killed.
Guru said he never got a fair trial and his brother reiterated that on Saturday, adding that authorities had not warned the family of his execution.
"At least the government should have given the family a chance to meet him," said the brother, Ajaz Ahmad Guru. "He didn't get a fair trial. His wife is in deep shock."
India said the Pakistan-based Jaish-e-Mohammad militant group was responsible for the parliament attack. The group fights Indian rule in Muslim-majority Kashmir.
The hanging last year of Mohammad Ajmal Kasab, the lone surviving Pakistani militant involved in the 2008 Mumbai attacks, after a long lull in executions, prompted speculation that India would move quickly to execute Guru.
But unlike Kasab's execution, which sparked celebrations in the streets, Guru's case was seen as more divisive.
Some Kashmiri leaders warned that hanging Afzal would fuel the revolt in India's part of the Himalayan region in which tens of thousands of people have been killed since 1989.
Curfews were imposed in Srinagar, the region's summer capital in the Kashmir valley, and major towns including Baramulla, Guru's home town.
Kashmir is divided between India and Pakistan, both of which claim the region in full and rule it in part. They have fought two of their three wars over the region.
In Pakistan-controlled Kashmir, more than 250 people took to the streets to protest against the hanging, shouting "Down with India" and burning an Indian flag.
India has long accused Muslim Pakistan of arming and funding militants to fight Indian forces in Kashmir. Pakistan says it only provides moral support to the fellow-Muslim people of Kashmir, who, Pakistan says, face harsh Indian rule.
The dispute, a legacy of the division of the sub-continent at the end of British rule, is the main factor souring relations between the neighbours.