The final five members of a young football team have been rescued from a flooded Thai cave after spending 18 treacherous days trapped deep inside, completing an astonishing against-the-odds rescue mission that captivated the world.
Thailand's Navy Seals said Facebook the remaining four boys and their 25-year-old coach were pulled to safety on Tuesday night.
Eight of the boys were rescued by Thai and international divers on Sunday and Monday.
Thais have been glued to their televisions, mobile phones and computer screens following every twist and turn of the boys' story, as have many people overseas.
Following word the final four boys and their coach had been pulled from the cave, there were scenes of jubilation across the country.
In the northern city of Chiang Rai, car horns were honked in the street and locals posed for selfies to show where they were when the astounding event happened.
Thais turned to social media on Tuesday to show their elation using the hashtag #Hooyah, a word used by the navy to build morale.
Other hashtags included #Heroes and #Thankyou.
The ups and downs of the rescue bid entranced Thailand and also fixated a global audience, drawing support from celebrities as varied as US President Donald Trump, football star Lionel Messi and tech guru Elon Musk.
"On behalf of the United States, congratulations to the Thai Navy Seals and all on the successful rescue of the 12 boys and their coach from the treacherous cave in Thailand," Trump tweeted. "Such a beautiful moment - all freed, great job!"
Britain's Manchester United football club said on its official Twitter page that it was relieved to learn that the 13 were safe and extended an invitation for the group and their rescuers to visit its Old Trafford stadium.
The rescue effort involved Thai and international agencies.
Authorities mulled ideas such as drilling holes into the mountain or waiting months until monsoon rains ended and they could walk out, with the rescue chief at one point dubbing the efforts to save them, "Mission Impossible".
With oxygen levels in their chamber falling to dangerous levels and monsoon rains threatening to flood the cave above the ledge where the boys were sheltering, rescuers decided on the least-worst option of having divers escort them out through the tunnels.
FIFA had extended an invite to the boys to watch the World Cup live in Russia - but the team won't make it to Sunday's final because of the strict quarantine measures.