Here is the timeline for what happened in the rescue watched around the world. For a look at live updates for the cave rescue, click here.
June 23: The boys and their coach go to the Tham Luang Nang Non cave to celebrate one of the team member's birthday. As they are exploring the cave, heavy rains begin and they become trapped. When none of the boys come home by evening, their parents begin to report them missing.
June 24: As the search begins, the boys' bicycles and other items are found near the cave entrance.
June 25: Authorities find more evidence that the boys likely went into the cave and became trapped. No one knows if they are alive.
June 26: The government brings in the Thai Navy SEALs to explore the cave, but find it difficult since water is filling the cave's chambers.
June 27: International cave diving experts are called on as more rain fills the caves. Pumps cannot keep up with the volume of water that needs to be pumped out.
June 28: Divers have to suspend the search because of water filling the cave. Teams begin drilling into the mountain to drain water.
June 29: Efforts to drain water from the caves is going slow because of more rain. Other options to try to find the team are explored. US and United Kingdom divers join the search.
June 30: Rescue efforts get a boost when the rains stop. More divers are able to go into the flooded caves and caverns to search for the team.
July 1: Navy SEALs reach the bend in the main passage of the cave and set up a staging area.
July 2: Ten days after the boys go into the cave, British cave divers find them. After they were found, the boys had a chance to send letters to their parents.
July 3: The world becomes more aware of what's happening in the cave as the video of the boys is released. Plans to get the boys out are considered, and people like SpaceX CEO Elon Musk offer their help.
July 4: Navy SEALs and a doctor get to the boys, bringing food and medicine. Officials ramp up efforts to pump the water out of the caves.
July 5: The SEALs begin to teach the boys how to dive. To get out of the caves the boys will have to walk where they can, but dive when they come to the portions of the escape route that are filled with water. None of the boys know how to dive. Some of them do not know how to swim.
July 6: While some have suggested that the boys stay in the caves until the monsoon season ends in Thailand several months from now, Thai officials say they want to get the boys out. On this day, a former Navy SEAL helping with the rescue dies from lack of oxygen.
July 7: The boys are still being trained in diving techniques. Officials announce the boys will be taken out of the cave using a buddy system with two divers for each boy. According to the Guardian, 40 Thai divers and 50 international divers with teams from the United States, Australia, the United Kingdom and China are part of the rescue attempt.
July 8: It's "D-Day" according to the Thai officials and the first four boys are safely brought out of the cave.
July 9: The second group of four boys is brought out. They are taken to the hospital where they join the first group of boys.
July 10: The last four boys and their coach are brought out of the cave, and the Thai Navy SEALs post on their Facebook page, "We are not sure if this is a miracle, a science, or what. All the thirteen Wild Boars are now out of the cave." The 12 boys and coach Chanthawong will remain in the hospital for at least a week, Thai officials said.