North Korea's second attempt to put a spy satellite into space has failed, three months after its first launch crashed into the sea.
The attempt on Thursday morning failed during the third stage of its flight, state media said.
For North Korean leader Kim Jong Un, a spy satellite is a coveted prize, as it would let him monitor incoming attacks and plot his own more accurately.
Pyongyang's space agency has said it will try again in October.
South Korea said it detected the launch of the rocket at around 03:50 local time (18:50 GMT), and that it had flown through international airspace over the Yellow Sea between mainland China and the Korean peninsula.
The launch prompted an emergency warning in Japan's southernmost Okinawa prefecture minutes later, urging residents to take cover indoors. The alert was lifted after about 20 minutes.
Condemning the launch, Japanese Prime Minister Fumio Kishida said: "Behaviour like this goes against the UN resolutions and we're already firmly protesting."
The US urged North Korea to refrain from "further threatening activity" and called on Pyongyang to engage in serious diplomacy.
But although Thursday's failure will have been disappointing for Pyongyang, it appears they've made progress.
A news report in state-run KCNA blamed the failure on "an error in the emergency blasting system during the third-stage flight", and said the problem was "not a big issue".
It seems the rocket carrying the satellite flew further than during the previous attempt. Officials in Pyongyang had described the botched attempt in May as their "gravest failure" while vowing to try again.
And Mr Kim will most likely continue, until he succeeds. Already he is forging ahead with his weapons programme, while refusing all offers to talk to the US.
Thursday's launch comes days after leaders from the US, Japan and South Korea met at a historic summit in Washington. It also follows the start of annual military exercises between Washington and Seoul.
Sign up for our morning newsletter and get BBC News in your inbox.
North Korea says spy satellite launch failed
North Korea tests 'most powerful' missile to date
What missiles has North Korea been testing?
More than 1,000 dead after strong Morocco earthquake
G20 laments suffering in Ukraine but no condemnation of Russia
Trump aide's challenge to Georgia election case fails
Earthquake hits historic Marrakesh – in pictures
Watch: Damage at historic mosque sparks fears of collapse. Video
Inside the horror of Europe's biggest wildfire
A tough choice in Ukraine – to have children or not
What is the G20 and why does it matter?
China's new chatbot has a censorship problem
French shrug off Muslim upset at abaya ban in schools
Stones, storms and ships: Photos of the week
The Nigerians learning to speak with British accents
Florida's first hurricane-proof town
The greatest spy novel ever written?
Why is everyone crazy about Aperol?
© 2023 BBC. The BBC is not responsible for the content of external sites. Read about our approach to external linking.