The leaders of North and South Korea have embraced after pledging to work for the "complete denuclearisation of the Korean peninsula", on a day of smiles and handshakes at the first inter-Korean summit in more than a decade.
The two Koreas announced they would work with the United States and China this year to declare an official end to the 1950s Korean War and seek an agreement on "permanent" and "solid" peace.
The declaration included promises to pursue phased arms reduction, cease hostile acts, transform their fortified border into a peace zone and seek multilateral talks with other countries including the United States.
"The two leaders declare before our people of 80 million and the entire world there will be no more war on the Korean peninsula and a new age of peace has begun," the two sides said.
South Korean President Moon Jae-in agreed to visit the North Korean capital of Pyongyang this year, they said.
Earlier, North Korea's Kim Jong-un became the first North Korean leader since the 1950-53 Korean War to set foot in South Korea after shaking hands with his counterpart over a concrete curb marking the border in the heavily fortified demilitarised zone.
Scenes of Mr Moon and Mr Kim joking and walking together marked a striking contrast to last year's barrage of North Korean missile tests and its largest ever nuclear test that led to sweeping international sanctions and fears of war.
Their meeting comes weeks before Kim is due to meet US President Donald Trump in what would be the first ever meeting between sitting leaders of the two countries.
Mr Trump welcomed the Korean talks.
"After a furious year of missile launches and Nuclear testing, a historic meeting between North and South Korea is now taking place. Good things are happening, but only time will tell!" he said on Twitter.
He later added: "KOREAN WAR TO END! The United States, and all of its GREAT people, should be very proud of what is now taking place in Korea!"
China, North Korea's main ally, welcomed the leaders' statement and said it was willing to keep playing a proactive role in promoting political solutions. China is wary of being sidelined by a thaw between the two Koreas and by the upcoming summit between Mr Trump and Mr Kim.
Russia said it was ready to facilitate cooperation between North and South Korea, including in the fields of railway transport and energy.
Japanese Prime Minister Shinzo Abe also welcomed the summit and said he expected North Korea to take concrete steps to carry out its promises.
Global markets were lifted by hopes the summit would pave the way for the end of conflict on the Korean peninsula.
As part of efforts to reduce tension, the two sides agreed to open a liaison office, stop propaganda broadcasts and leaflet drops along the border and allow Korean families divided by the border to meet.
Earlier, Mr Moon greeted Kim at the military demarcation line where the men smiled and shook hands.
In an unplanned move, Mr Kim invited Mr Moon to step briefly across into North Korea, before the two leaders crossed back into South Korea holding hands.
"I was excited to meet at this historic place and it is really moving that you came all the way to the demarcation line to greet me in person," Kim said.
"A new history starts now. An age of peace, from the starting point of history," Kim wrote in Korean in a guest book in the South's Peace House before talks began.
Mr Moon and Mr Kim released their joint declaration before a dinner banquet.
After warm farewells, Kim was driven back to North Korea.