The former King of Afghanistan, Zahir Shah, has died at the age of 92 following a long illness.
Many Afghans remember Zahir Shah's reign fondly
President Hamid Karzai announced three days of mourning. He said Zahir Shah had been a symbol of national unity.
Zahir Shah was deposed in 1973 and went into exile. He returned to Afghanistan in 2002 after the fall of the Taleban but was given no official role.
He was popular among Afghans and his reign is remembered as a time of peace before Soviet invasion and war.
Zahir Shah died at his Kabul residence in the presidential palace compound.
His body is lying in state at a Kabul mosque and all television and radio stations are reciting Koranic verses.
The funeral will be held on Tuesday when prayer ceremonies will take place across Afghanistan.
"With paramount grief, I would like to inform my countrymen that... Mohammad Zahir Shah has bid farewell to this mortal world," President Karzai said.
"We announce three days of national mourning over the death of the father of the nation, and the Afghan flag will be at half mast for three days."
Zahir Shah's 40-year reign saw modest political reform with women receiving education and voting in elections, and a free press.
The former king spent nearly three decades in exile
He had returned to Kabul in 2002 after 29 years abroad, mostly spent in Italy.
During his long exile, the former king witnessed his country laid low by war, and the rise of the harsh Islamic regime of the Taleban.
Born in Kabul in 1914, Zahir Shah was educated in France and was only 19 when he ascended the throne in 1933 after his father was assassinated.
After World War II, in which he succeeded in maintaining both Afghanistan's neutrality and its borders, the king recognised the need for modernisation.
Zahir Shah brought in foreign advisers, founded the first modern university, and fostered cultural and commercial relations with Europe.
But amid the modernisation, dark undercurrents of wrangling between the country's tribal factions remained.
In July 1973, while he was in Italy receiving medical treatment for an eye condition, Zahir Shah was ousted in a coup orchestrated by his cousin, Mohammad Daoud.
Daoud opposed his efforts to open up the country and develop contacts with the West.
In the years following the coup, the last monarch of a 200-year-old Pashtun dynasty lived in a villa outside Rome.
During this time Afghanistan descended into factional violence and war.
In 2002, Zahir Shah returned to his country to attend a meeting, known as a loya jirga, to decide Afghanistan's future.
He moved back into his former palace in the capital, Kabul, as part of an agreement reached at the meeting.
He had agreed not to stand against Hamid Karzai for the post of Afghan head of state.
"It gives me great pleasure to come back, great pleasure," the monarch said on returning to his country.
Despite being viewed by some Afghans as a potential threat, Zahir Shah was seen as the one figure who could bridge the country's divisions, says the BBC's Catherine Davis.
He was given the symbolic title, Father of the Nation - though he was an ethnic Pashtun, he was keen to distance himself from politics and tribal loyalties.
The former king and his wife had five sons and two daughters. One son, Shah Mahmoud Zahir, died in Rome in 2002 at the age of 56.
Zahir Shah's wife, Homaira, died as preparations were being made for her to join him in Kabul in 2002.