Donald Trump has accepted North Korean leader Kim Jong-un’s invitation to meet, an extraordinary turn of events that followed months of rising tensions between the two nations.

South Korea’s National Security Advisor Chung Eui-Yong told reporters at the White House that North Korea expressed a willingness to refrain from testing missiles and nuclear weapons and said Mr Trump pledged to meet by May in an effort to achieve “permanent denuclearisation”.

Mr Trump confirmed that he would accept Mr Kim’s invitation but said that sanctions would stay intact.

“Kim Jong Un talked about denuclearisation with the South Korean Representatives, not just a freeze,” Mr Trump tweeted following Mr Chung’s announcement. “Also, no missile testing by North Korea during this period of time. Great progress being made but sanctions will remain until an agreement is reached. Meeting being planned!”

No sitting US president has ever met with a North Korean leader. Mr Trump said last May that he would be willing to meet with Mr Kim “under the right circumstances”. But that remark was followed by months of heightened tensions and flame-throwing between the two leaders.

Now, after maximum pressure on Mr Kim’s regime, a senior administration official said, North Korea now appears ready for some kind of dialogue. But Mr Trump has “been very clear from the beginning” that he will not reward North Korea for talks, the official added, and will only accept the permanent denuclearisation of North Korea.

“We look forward to the denuclearisation of North Korea”, White House Press Secretary Sarah Huckabee Sanders said in a statement. “In the meantime, all sanctions and maximum pressure must remain”.

Mr Chung said North Korea did not demand a precondition long cited by Pyongyang: a cessation of joint military exercises between the US and South Korea, which it regularly denounces as provocations and rehearsals for an invasion.

“He understands that the routine joint military exercises between the Republic of Korea and the Unites States must continue”, Mr Chung said.

Mr Kim’s offer presents an opportunity for a breakthrough at a time when military officials have warned that North Korea’s increasing military sophistication – and its progress toward becoming a nuclear-armed state – pose an urgent threat.

Mounting belligerence from Pyongyang has loomed over Mr Trump’s first year in office, testing the limits of international diplomacy and raising the spectre of nuclear conflict. North Korea has tested multiple ballistic missiles and threatened to annihilate its neighbours; Mr Trump and his surrogates have responded by saying they’re prepared to launch an overwhelming military response.

North Korea Military Parade Show all 6 1 /6 North Korea Military Parade North Korea Military Parade In this image made from video released by KRT on Feb. 8, 2018, a military parade is held at Kim Il Sung Square in Pyongyang, Thursday, Feb. 8 2018, just one day before South Korea holds the opening ceremony for the Pyeongchang Winter Olympics. (KRT via AP Photo) AP North Korea Military Parade This screen grab taken from North Korea's KCTV on February 8, 2018 shows members of North Korea's military taking part in a parade, with missiles being displayed, in Kim Il Sung Square in Pyongyang. North Korea staged a military parade in Pyongyang on February 8 to mark the 70th anniversary of its armed forces, in a show of strength just a day before the Pyeongchang 2018 Winter Olympic Games open in the South. / AFP PHOTO / KCTV / KCTV / -----EDITORS NOTE --- RESTRICTED TO EDITORIAL USE - MANDATORY CREDIT "AFP PHOTO / KCTV" - NO MARKETING - NO ADVERTISING CAMPAIGNS - DISTRIBUTED AS A SERVICE TO CLIENTS - NO ARCHIVESKCTV/AFP/Getty Images AFP/Getty Images North Korea Military Parade In this image made from video released by KRT, North Korean soldiers march during a military parade in Pyongyang, Thursday, Feb. 8 2018. North Korea held a military parade and rally on Kim Il Sung Square on Thursday, just one day before South Korea holds the opening ceremony for the Pyeongchang Winter Olympics. (KRT via AP Photo) AP North Korea Military Parade In this image made from video released by KRT on Feb. 8, 2018, North Korean leader Kim Jong Un, right, inspects honor guards, along with his wife Ri Sol Ju, center, during a military parade in Pyongyang, Thursday, Feb. 8 2018. North Korea held a military parade and rally on Kim Il Sung Square on Thursday, just one day before South Korea holds the opening ceremony for the Pyeongchang Winter Olympics. (KRT via AP Photo) AP North Korea Military Parade In this image made from video released by KRT on Feb. 8, 2018, North Korean leader Kim Jong Un, center, watches the military parade in Pyongyang, Thursday, Feb. 8 2018. North Korea held a military parade and rally on Kim Il Sung Square on Thursday, just one day before South Korea holds the opening ceremony for the Pyeongchang Winter Olympics. (KRT via AP Photo) AP North Korea Military Parade This screen grab taken from North Korea's KCTV on February 8, 2018 shows North Korean leader Kim Jong Un speaking during a military parade in Kim Il Sung Square in Pyongyang. North Korea staged a military parade in Pyongyang on February 8 to mark the 70th anniversary of its armed forces, in a show of strength just a day before the Pyeongchang 2018 Winter Olympic Games open in the South. / AFP PHOTO / KCTV / KCTV / -----EDITORS NOTE --- RESTRICTED TO EDITORIAL USE - MANDATORY CREDIT "AFP PHOTO / KCTV" - NO MARKETING - NO ADVERTISING CAMPAIGNS - DISTRIBUTED AS A SERVICE TO CLIENTS - NO ARCHIVESKCTV/AFP/Getty Images AFP/Getty Images

Rhetorical sparring between the two countries’ leaders escalated the standoff. After the President derisively nicknamed the North Korean leader “Little Rocket Man” and threatened to “totally destroy” North Korea during a speech to the United Nations, Mr Kim issued a rare direct response dismissing Mr Trump as a “mentally deranged US dotard”.

But during the Winter Olympics in Pyeongchang, South Korea cracked open a diplomatic window after North Korea sent athletes and representatives south of the demilitarised zone. South Korean envoys returned from a rare, post-Olympics visit to Pyongyang with a message that North Korea was willing to negotiate with the US around renouncing its nuclear arms programme.

The President initially reacted to the overture with cautious optimism, hailing the first “serious effort” at progress in years but hedging against “false hope”.

North Korea indicates it could give up nuclear weapons, according to the South

“I think that they are sincere”, Mr Trump said at the White House earlier this week, noting that multiple rounds of sanctions imposed by the United Nations in recent months have been “very, very strong and very biting”.

Mr Trump’s embrace of meeting with Mr Kim appeared to contradict his Secretary of State, Rex Tillerson, who earlier in the day called direct talks unlikely to take place soon.

“We’re a long ways from negotiations,“ Mr Tillerson said during a news conference in Ethiopia, adding that “we just need to be very clear-eyed and realistic about it”.

Even amid signs of a thaw, the US has continued to condemn North Korean aggression. Earlier this week the State Department announced new sanctions, saying North Korea had directed the assassination of Mr Kim’s half-brother used a banned chemical agent.

Secretary of State Rex Tillerson said earlier while on a tour in Africa that “we’re a long way from negotiations” with North Korea.

“We just need to be very clear-eyed and realistic about it,” he added.

Republican Representative Ed Royce, the chairman of the House Foreign Affairs Committee, said North Korea’s desire to talk with Mr Trump shows that sanctions are “starting to work”.

The administration can “pursue more diplomacy, as we keep applying pressure,” he added.

Jeffrey Lewis, of the Middlebury Institute of International Studies in California, said that Mr Kim is not inviting Trump so that he can surrender North Korea’s weapons.

“Kim is inviting Trump to demonstrate that his investment in nuclear and missile capabilities has forced the United States to treat him as an equal,” Mr Lewis wrote on Twitter.