North Korean leader Kim Jong-il has died at the age of 69, state-run television has announced.
Mr Kim, who has led the communist nation since the death of his father in 1994, died on a train while visiting an area outside the capital, the announcement said.
He suffered a stroke in 2008 and was absent from public view for months.
His designated successor is his third son, Kim Jong-un, who is thought to be in his late 20s.
North Korea's state-run news agency, KCNA, urged people to unite behind the younger Kim.
"All party members, military men and the public should faithfully follow the leadership of comrade Kim Jong-un and protect and further strengthen the unified front of the party, military and the public," the news agency said.
State media also referred to him as the "great successor to the revolutionary cause" in what appeared to be the first such reference.
A funeral for Kim Jong-il will be held in Pyongyang on 28 December and Kim Jong-un will head the funeral committee, KCNA reports. A period of national mourning has been declared from 17 to 29 December.
The BBC's Lucy Williamson in Seoul says Mr Kim's death will cause huge shock waves across North Korea, an impoverished, nuclear-armed nation with few allies.
The announcement came in an emotional statement read out on national television.
The announcer, wearing black, said he had died of physical and mental over-work. A later report from KCNA said Mr Kim had had a heart attack.
China - North Korea's closest ally and biggest trading partner - said it was "distressed" to hear the news of his death.
"We express our grief about this and extend our condolences to the people of North Korea," Foreign Ministry spokesman Ma Zhaoxu was quoted by Xinhua news agency as saying.
South Korea's military has been put on alert following the announcement and its National Security Council is convening for an emergency meeting, Yonhap news agency reports. The Japanese government has also convened a special security meeting.
be interesting to see how this develops with his son taking over