After nine days trapped in a flooded Thai cave, 12 boys and their football coach have been found alive. Here’s how the gruelling nine-day search unfolded in Tham Luang Nang Non cave, a 10km-long system filled with fast-flowing muddy floodwaters.

Saturday, 23 June

The boys, aged between 11 and 16, and their 25-year-old coach, Ekkapol Chantawong, went into the Tham Luang Nang Non cave in northern Thailand after football practice. They were reported missing by a mother after her son did not come home that night.

Local officials start to look for the boys after they are believed to have become trapped by heavy rains that cut them off from the main entrance. They find bicycles locked to a fence and shoes and football boots belonging to the kids close to the entrance.

Sunday 24 June

Park officials and police begin a major search operation and heavy rains continue to fall in the area near the Laos and Myanmar borders. They find handprints and footprints believed to belong to the boys and believe they probably retreated into the winding tunnels as they became hemmed in by rising floodwaters.

Relatives keep a vigil outside the cave, desperately awaiting news.

Monday 25 June

Thai Navy Seal divers are in the cave searching for the boys, carrying oxygen tanks and food.

Makeshift shrines are set up for parents to pray and make offerings.

Heavy rains continue, sparking fears that floodwaters within the cave could rise.

The boys are believed to have retreated further into the cave, to an elevated air pocket called “Pattaya Beach”.

Tuesday 26 June

Divers reach a T-junction several kilometres inside the cave but are forced back by rushing floodwaters that clog a narrow crevice near Pattaya Beach.

Thailand’s junta leader Prayuth Chan ocha calls for the nation to support the rescue.

Wednesday 27 June

A team of more than 30 American military personnel from the US Pacific Command, including pararescue and survival specialists, arrive at the site in the evening. They are joined by three British diving experts who go into the cave’s entrance but quickly retreat because of heavy flooding.

Continuing rains are causing flood levels to rise, and officials say conditions are “difficult”.

Thursday 28 June

The underwater search is temporarily halted because of the fast-moving floods inside the cave as downpours refuse to let up.

Water pumps are brought in to drain the rising floodwaters that are so murky it is likened to swimming through cold coffee.

American experts get to work around the base, while the three British divers and others scour the mountain for alternative entrances into the cave.

Drones are sent to help find new chimneys that reach down into the cave.

Friday 29 June

A glimmer of hope as rescue teams find a possible opening, but there is no guarantee it will connect to the main cave network.

Prayuth Chan Ocha visits the site and leads a meditation, jokes and cooks with relatives, and urges them not to give up hope.

Saturday 30 June

A break in the bad weather allows divers to reach further inside the cave but they are still several kilometres away from where the boys are believed to be.

Teams continue to search for alternative openings above ground and rescuers conduct practice drills to safely evacuate the boys if and when they are found.

Sunday 1 July

Divers inch further into the cave, taking advantage of the brief break in the weather.

Rescuers set up an operating base inside the cave and hundreds of oxygen tanks and other supplies are pulleyed in. Divers can now stay remain underground for longer.

As the the sun breaks out, Narongsak Osottanakorne, the governoer of Chiang Rai province, says conditions for the operation are improving.

Monday 2 July

A miracle: the 12 boys and their coach are found alive and safe about 400 metres further along from Pattaya Beach – which had become threatened by encroaching floodwaters.

Crowds at the rescue site cheer the good news and a nation breathes a sigh of relief.

The priority is to get the boys and their coach food and first aid after nine days with little to eat in difficult conditions. Then there is the task of getting them out safely. None of the boys can swim.

It could take days – or weeks – to get them out. Rescuers explore several options, including training them to use scuba equipment.