CIA director Mike Pompeo travelled to Pyongyang for a secret meeting with North Korean leader Kim Jong-un, US President Donald Trump has confirmed.
A "good relationship" was formed at the meeting last week, Mr Trump tweeted on Wednesday.
News of the visit first emerged on Tuesday. US officials were quoted as saying the aim was to prepare a summit between Mr Trump and Mr Kim.
Mr Trump had earlier alluded to high-level direct talks with Pyongyang.
But the unexpected and clandestine meeting marks the highest level US contact with North Korea since 2000.
"We have had direct talks at... extremely high levels," Mr Trump said from Florida, where he is hosting Japan's Prime Minister Shinzo Abe.
The president added that he gave his "blessing" for talks between the South and North to discuss a peace treaty to formally end the 1950-1953 Korean War.
South Korea has also signalled that it may pursue a formal resolution of the conflict.
South Korea's President Moon Jae-in and Mr Kim are due to meet next week. The two sides have agreed to broadcast parts of the summit live, the South's state news agency Yonhap reported.
What do we know about the 'secret meeting'?
The news that Mr Pompeo had travelled to North Korea for a clandestine meeting with Mr Kim was first reported by The Washington Post.
The trip took place shortly after Mr Pompeo was nominated by Mr Trump to replace Rex Tillerson as secretary of state, two anonymous sources "with direct knowledge of the trip" told the newspaper.
Later Reuters news agency said the report had been confirmed to them by senior officials. Early on Wednesday, Mr Trump confirmed the reports with a tweet.
Mike Pompeo met with Kim Jong Un in North Korea last week. Meeting went very smoothly and a good relationship was formed. Details of Summit are being worked out now. Denuclearization will be a great thing for World, but also for North Korea!— Donald J. Trump (@realDonaldTrump) April 18, 2018
Very little is known about the talks other than that they were to prepare for the forthcoming Trump-Kim summit.
Mr Pompeo is predicted to be confirmed as the top US diplomat by the Republican-controlled Senate in coming weeks.
This is despite mounting speculation that he will, unusually, fail to receive the backing of the bipartisan Senate Foreign Relations Committee following a grilling of more than five hours by the committee last week.
How do the US and North Korea communicate?
The US does not have diplomatic relations with North Korea, although diplomats have visited in the past and there are some so-called "back channels" used to communicate with Pyongyang.
Mr Pompeo's trip was the highest level meeting with a North Korean leader since 2000 when then-Secretary of State Madeleine Albright met Kim Jong-il, the father of the current leader, in Pyongyang.
In 2014, the then-head of National Intelligence James Clapper visited North Korea in a secret mission to negotiate the release of two US citizens. Mr Clapper did not meet the North Korean leader during his trip.
When and where might a summit take place?
Mr Trump stunned the international community last month by accepting Pyongyang's suggestion for direct talks. It would be unprecedented for a sitting US president to meet a North Korean leader.
He said the summit would take place either in early June or "a little before that" and that several sites were under consideration but that none of them were in the US.
Analysts have speculated that a location for talks could be the demilitarised zone between North and South Korea, Beijing, another Asian country, Europe or even a vessel in international waters.
North Korea has been isolated for decades because of its well-documented human rights abuses and its pursuit of nuclear weapons, in defiance of international laws and UN sanctions.
It has carried out six nuclear tests, and has missiles that it says could reach the US.
But South Korea's hosting of the Winter Olympics in February gave an unexpected window for diplomacy, and in the weeks since there have been a flurry of visits to the North from China, South Korea and now the US.
What does the timing of this news tell us?
Mr Trump's estimate that a meeting could take place in June or earlier appears to be one the administration is taking seriously.
But news of Mr Pompeo's visit is also likely to overshadow delicate talks with Japan, a key US ally and neighbour of North Korea.
There have been fears in Tokyo that Mr Trump's plans for bilateral talks could sideline Japan, and Mr Abe is currently in Florida for talks with the US leader.
Relations between the two men appeared cordial on this, the second time that Mr Trump has welcomed Mr Abe to his Mar-a-Lago resort.
Mr Trump insisted on Tuesday that the two countries were "very unified on the subject of North Korea", and Mr Abe praised the US president's handling of the North Korea issue.
However, observers say Mr Abe's goal for his US trip will be to persuade the US president as much as he can not to sway from the West's hard line on Pyongyang.
The Japanese prime minister has repeatedly sought to portray a close personal relationship with Mr Trump and was the first foreign leader to meet him in New York after his election victory in 2016.