The game opens with Hinawa and her two children Lucas and Claus at Tazmily Village visiting her father Alec. After a few days they start their walk back home just as a mysterious group of uniformed men wearing pig masks invade the nearby forest. The trees of the forest suddenly catch fire, and a Drago (a dinosaur-like creature that is normally friendly) violently kills Hinawa. The Pigmasks reveal that they used cybernetics to turn the once-friendly creature into a mindless killing machine. When Hinawa's husband, Flint, finds out about this, he becomes consumed with rage and sadness. He vents his anger by attacking the other villagers, and is finally knocked unconscious and arrested. The next day Claus visits Flint in jail and gives him a tool to escape, also promising that he will avenge Hinawa's death. After escaping jail Flint finds out from Lucas that Claus left the village with a knife, and has indeed gone after the Mecha-Drago. Flint, determined to save his son, goes with Alec into the mountains where the Dragos live. They find Claus's shoes but their search is interrupted by the enraged Mecha-Drago, and they defeat it after a tiring battle. A baby Drago defends the dying mecha one, and Alec convinces Flint not to strike the killing blow by comparing this to Hinawa's death. Exhausted, they abandon their search for Claus and Flint accepts it.
Soon after, thief-in-training Duster goes with his father, Wess, to retrieve the Hummingbird's Egg from Osohe Castle. They meet Kumatora, the princess of Osohe Castle, and find that the egg is booby trapped, and the trio are sent into the castle's sewer system. Kumatora and Wess wash up on a sandbank, but Duster goes missing, losing his memory and eventually becoming the bass player for a popular band that performs at the nearby Club Titiboo. He hides the egg in the process, not knowing what it is. Meanwhile, a banana-loving man named Yokuba (Fassad in translated versions) starts to sell enigmatic "Happy Boxes" to the villagers.
Three years after Tazmily has been transformed into a fiercely consumerist society with a monetary system in place for the first time, a Happy Box appears in nearly every house. Pigmasks have installed a military base in the town, and hire villagers to work for them at facilities around the island. Lucas learns about his mother dead and his brother missing and Flint spends all of his time up in the mountains searching for Claus. Lucas goes around town and sees all of the changes the Pigmasks have made. He finds Wess in a dirty retirement home which has replaced his house. Wess asks Lucas to find Duster, so Lucas goes with his dog Boney to Club Titiboo in search of him. Right after he leaves, he meets Ionia, a member of a group of beings who are thousands of years old known as the Magypsies. Ionia teaches Lucas how to use PSI (a mental ability that is useful in combat) and reveals that Lucas can use a unique offensive ability called PSI Love to imply that he also taught it to Claus in his past. Lucas and Boney sneak into the club and meet Kumatora, who is also looking for Duster while disguised as a waitress. The three of them find Duster, restore his memories, and convince him to help them find the Hummingbird Egg. They do so, and demolish a lightning generator tower that has been destroying the homes of villagers not willing to conform to the monetary system or buy Happy Boxes. They are chased to the top of the tower by Fassad, who slips on one of his own banana peels and falls off. They try to escape by hanging from the ladder of a Pigmask ship, but are thrown off. Lucas and Boney awaken in a field of sunflowers, where they see Hinawa's ghost. Lucas runs after her, accidentally running off the side of a cliff and onto a haystack. They meet Ionia again, who tells Lucas about the Seven Needles which seal off the gigantic "Dark Dragon" hidden under the island. Whether the world would be destroyed or created anew upon the Dragon's release depends on whether the one who pulls them is good or evil. They set off to pull as many of the needles as they can before a mysterious Masked Man leading the Pigmasks transfers his own heart onto the dragon. On the way they reunite with Kumatora and Duster. After Lucas and the Masked Man manage to pull three needles each, Lucas, Kumatora, Duster and Boney are invited to the neon superhaven New Pork City by Master Porky, leader of the Pigmasks. The city turns out to be mostly made out of crude, childish theme park attractions and fake cardboard buildings. They find an imprisoned Leder, the village's bell-ringer, who speaks for the first time and tells Lucas that there once existed a world much different from Nowhere Islands. The world wound up being destroyed by the humans who inhabited it. Before apocalypse, a white ship carried people to the Nowhere Islands where they worked to create a utopia under the Dragon's protection. They replaced their memories of the old world with the new one of Nowhere Islands to prevent them from destroying the islands as well. The Hummingbird Egg was created to store the old memories. Leder watched over the village as the only one who retained his memories, ringing a bell to keep their memories from reverting. He reveals that Porky discovered the islands by time traveling, filling his city with people taken from other eras (most of whom work as Pigmasks). Porky learned of the white ship and the Dragon from Locria, who betrayed the Magypsies. Since Porky could not pull the Needles, he turned the Masked Man (who could pull the needles because he can use PSI Love) into a soulless cyborg under his control. Leder urges Lucas and his friends to pull the seventh needle before the Masked Man so that the world will be created anew instead of destroyed. Fassad later battles them in New Pork City and is defeated for the last time. They later discover that Fassad was the final Magypsy, Locria.
On the 100th floor of the "Empire Porky Building" they meet Master Porky, who turns out to be an old man with the mind of a child (and as a child he was the primary antagonist of EarthBound). After being suddenly dropped into an elevator, Lucas, Kumatora, Duster, and Boney, along with Flint (who goes his separate way) go down to the Needle and Lucas' party battle Porky. Even though his extensive time traveling has rendered him unable to die, Porky's machine runs out of energy after being severely damaged, and he decides to encase himself in a completely impenetrable capsule. However, the capsule cannot be reopened, and Porky cannot attack, trapping Porky inside for eternity. When Lucas reaches the needle he is attacked by the Masked Man, and discovers that the Masked Man is actually his twin Claus. Flint, Kumatora, Duster, and Boney are knocked unconscious by Claus's PSI lighting, but due to Lucas' Franklin Badge, it reflects back and strikes Claus, leaving Lucas unharmed. Lucas and Claus begin their final duel.
Lucas is unable to bring himself to attack his twin brother, even as he attacks Flint who attempts in vain to bring Claus to his senses. Hinawa's ghost pleads with Lucas and Claus to stop fighting, and eventually Claus regains his memories and with his what little control of his body he has left, kills himself by reflecting his PSI lighting attack on Lucas' Franklin Badge one last time in order to free his soul. Claus draws his last breath, and Lucas pulls the final Needle. This leads to a cataclysmic event involving the islands ripping into pieces. After the credits and the game's "END?" screen, the player can move around on a blank screen and talk to all of the characters. Because the player can talk to Lucas, who is the playable character for most of the game, it seems that the player is interacting with the characters directly (instead of through another character.) All of the characters reassure the player that they are fine despite the islands being destroyed, and say goodbye to the player. Whether this is the afterlife or someplace that the people escaped to is left ambiguous. However, if what Ionia said is true, Lucas made the dragon and rebuilt the world. Finally the credits roll, the real "END" screen, and the game's wooden title is shown.