Thailand's King Bhumibol Adulyadej, the world's longest-reigning monarch, has died at the age of 88, the palace announced Thursday, leaving a divided nation bereft of a rare figure of unity.
President Barack Obama led global tributes to Bhumibol, whose death ends a remarkable seven-decade reign and plunges Thailand into a deeply uncertain future.
Most Thais have known no other monarch and he has been portrayed as a guiding light through decades of political turmoil, coups and violent unrest.
In a statement the palace said the king passed away at 3:52 pm (0852 GMT).
As the news filtered out, large crowds erupted in mourning outside the hospital where Bhumibol spent most of the last two years, many of them wailing and sobbing.
"How will Thailand live without you father?" cried one distressed young man as others chanted "Long Live the King!"
Prime Minister Prayut Chan-O-Cha, the former army chief who leads Thailand's ruling junta, described the king's passing as "the most devastating moment for Thais" since the death of his predecessor and older brother Ananda in 1946.
RELATED: Thailand Destroys Illegal Ivory Stockpile
He moved quickly to declare that the king's 64-year-old son, Crown Prince Maha Vajiralongkorn, is the named successor.
The crown prince is much less well-known to Thais and has yet to attain his father's widespread popularity. He spends much of his time overseas, especially in Germany, and is a keen pilot.
Crown prince seeks delay
The prime minister said late Thursday that the country's crown prince has asked for time before being officially proclaimed the next monarch following the death of his father.
"He asked for time to prepare for legal processes in order to proclaim him on the throne at the appropriate time," Prayut told reporters at Government House after holding an audience with Crown Prince Maha Vajiralongkorn.
In a unexpected announcement that could fuel concerns over the succession, Prayut added the prince asked for "time to prepare and expressed regret together with the Thai people" for the loss of his father.
The 64-year-old prince has been Bhumibol's named successor since 1972.
The latest announcement now suggests there will be a delay between Vajiralongkorn being officially made the next king as he mourns his father and prepares to take on the royal mantle.
"When the appropriate time comes, the crown prince said he is already aware of his duty as the heir or crown prince," Prayut told reporters.
"I hope everyone will understand and not cause chaos," he added.
Bhumibol was immediately proclaimed successor the same day his brother died in 1946.
Thailand's parliament held a late night special session at which many had expected the crown prince to be officially proclaimed the new king by lawmakers.
But the session ended after a short statement was read out announcing Bhumibol's death and after a 9-minute silence was held for the deceased monarch, marking his official title Rama IX.
In a televised address to the nation, Prayut said Thailand would hold a one-year mourning period and that all entertainment functions must be "toned down" for a month.
Trading on the Thai stock exchange would not be suspended, he added.
Bhumibol's death is a major test for the country's generals, who seized power in 2014 vowing to restore stability after a decade of political chaos, a turbulent period exacerbated by the king's declining health as jostling elites competed for power.
The military has deep links with the palace and many inside the kingdom saw the coup as a move to ensure generals could stamp down on any instability during a succession.
It is difficult to overestimate Bhumibol's importance to most of his subjects.
RELATED: Thailand's Underground Bike Revolution
Backed by an intense palace-driven personality cult, he is revered as a demigod by many, seen as rising above the kingdom's notoriously fractious political scene.
It is not unusual to see Thais moved to tears when they talk of a future without him.
Officially known as King Rama IX, he descended from the Chakri dynasty which came to power in Thailand in the late eighteenth century.
His subjects have had many years to get used to the prospect of no longer having Bhumibol - their king has not been seen in public for months and has suffered prolonged ill health.
But his passing is still a huge shock to the nation.
His reign spanned a remarkable era in which Thailand transformed itself from an impoverished, rural nation into one of the region's most successful economies, dodging the civil wars and communist takeovers of its neighbours.
He built a reputation for criss-crossing the nation to visit the rural poor and sometimes intervened to quell key moments of political violence - although other times he stayed silent and he approved most of the army's many coups during his reign.
In a statement Obama described Bhumibol as a "close friend" and "tireless champion" of his country's development. UN Secretary General Ban Ki-moon said he was a "unifying national leader... respected internationally."
Any criticism or effective republican sentiment has been erased inside Thailand by a draconian lese majeste law, use of which has surged since the military's latest takeover.
In recent years, and especially since the 2014 coup, the heir apparent Vajiralongkorn has made more frequent public appearances inside Thailand and taken on a larger number of royal engagements.
He will inherit one of the world's richest monarchies.
During his reign Bhumibol, with his establishment allies, built up a multi-billion-dollar-empire spanning property, construction and banks under the banner of the Crown Property Bureau (CPB).
Analysts say the CBP's vast reserves allowed the crown to build a deep network among the Thai elite, helping insulate the king from the political pressures felt by monarchs who rely chiefly on state funding.
The palace's announcement that the king was gravely ill sent shudders through the stock market and pushed the baht currency to a two-month low earlier this week.
"The death of Thailand's highly-revered king will plunge the country into a state of mourning, and also deep political uncertainty," Capital Economics said in a note.
"There is a risk that political tensions flare up, triggering a slowdown in economic growth," it said. "All eyes now will turn to the succession process."
WATCH: What Is Martial Law And How Does It Work?