Here's a breakdown of how the main characters leave the island:
* The Oceanic Six: This group, consisting of Jack, Kate, Hurley, Sayid, Sun, and Jin, are seemingly rescued by Penelope Widmore's yacht. They are then believed to have died in the crash, becoming the "Oceanic Six" who survived. However, they actually leave the island through a series of events involving time travel and a special "doorway" created by the island itself.
* Desmond: He escapes the island by jumping through a time portal created by the electromagnetic field, leaving the island in 1996, years before the crash.
* Benjamin Linus: He leaves the island in the "flash sideways" timeline, ultimately reunited with his daughter.
* Others: Various characters, including John Locke, Sawyer, and Juliet, experience different fates depending on the timeline. Some leave the island, while others stay, often making the ultimate sacrifice.
It's important to note: The way the characters leave the island is intertwined with the island's mystery and its "rules." They are not simply escaping a physical prison but transcending their personal struggles and achieving a sense of peace.
The "flash sideways" timeline: This timeline, shown in the final season, depicts an alternate reality where the Oceanic 815 never crashed. It acts as a metaphorical escape for the characters, allowing them to find closure and happiness without the island's influence.
Ultimately, the way each character leaves the island represents their journey towards self-discovery, redemption, and acceptance.