As Ash and his friends are walking along Mandarin Island to the Gym in Trovita, a rolling storm forces the gang to take cover. During the storm, they see a small crowd of Magnemite being struck by lightning and find that they are absorbing the electricity. Eventually, they see a Jolteon that seems to be herding the crowd of Magnemite. They also meet a man who has a wagon with a pair of Tauros pulling it. He offers them safety in the back of the wagon from the lightning; they do so and board the wagon.
After the storm passes, the man introduces himself as Ethan, a Magnemite rancher. He explains that he takes his Magnemite into thunderstorms so that he can take the absorbed electricity to towns and cities on the island. Tracey notices how well-trained the Magnemite are and asks Ethan about it. Ethan explains that he calls the Magnemite by numbers instead of names, while Jolteon is used to round up the Magnemite. The Magnemite take a liking to Pikachu and almost swallow him. Ash attempts to help Pikachu, but ends up getting shocked himself.
While Jolteon leads the Magnemite, Ethan takes the gang to the next town. At sunset, Ash decides to take the reigns from Ethan to the Tauros but almost crashes it on his first try. However, he eventually gets the hang of it. Later at night, during another thunderstorm, the gang watches as the Magnemite absorb more lightning. Meanwhile, Team Rocket plots to kidnap Pikachu, Jolteon, and the group of Magnemite and profit from their electric power before giving them to Giovanni.
The next day, Ethan receives a phone call from the Officer Jenny in a nearby town, telling them that they need power due to a blackout. The phone call is interrupted soon after and the Magnemite fly away, with Jolteon in pursuit. They run into Team Rocket, who recite their motto and announce their intentions. They use a giant magnet and gripper to kidnap Pikachu, Jolteon, and the Magnemite. Pikachu tries to use Thunder Shock, but it does no damage due to the gripper being lightning-absorbent. Ethan commands Jolteon to instead use Pin Missile, which frees both Pokémon. Jolteon then uses Thunder Wave in an attempt to gain control of the magnet, but Jessie goes into a rage and calls out Arbok. Jolteon manages to get all of the Magnemite free, but it is left open to a Tackle attack from Arbok. Jolteon flies back into Ethan, who in turn hurts his arm on a rock. Pikachu manages to finish the battle by using Thunderbolt on Team Rocket, sending them flying off.
Despite his injuries, Ethan intends to take the Magnemite to the town for their electric power. As a result, Ash volunteers to take the Magnemite to town for Ethan. He straps up one of the Tauros and Ethan instructs him to take nine of the Magnemite, which he does. Using the whistle that controls the Magnemite, Ash initially does pretty well until the Magnemite start vanishing in different directions. When the whistle fails to bring them back, Pikachu uses Thunderbolt to herd the Magnemite. While doing a roll-call for the Magnemite, Ash finds that Number 6, a very strange-looking Magnemite, is missing and goes off to look for it.
Number 6 is found floating away over the stream, just as Team Rocket returns with magnet machines that are powered by rubbing themselves with panels that work on static electricity. Ash flees with Number 6 until he runs into Pikachu, leading Team Rocket to the other Magnemite in the process. Ash orders Pikachu to run with the other Magnemite, but he does not. The other Magnemite are bagged by Team Rocket, but Pikachu tries to battle their magnets with his own Electric attacks.
Seeing Pikachu trying desperately to save its fellow Magnemite, Number 6 flies into the colliding magnetic blasts. Absorbing all of the electricity, it manages to free the other Magnemite and evolve into Magneton. The other eight Magnemite use their own power to restore Pikachu. Team Rocket tries to get the Pokémon back with their magnets by rubbing themselves harder, but they accidentally set themselves on fire instead. Pikachu, the Magnemite, and Number 6 use their combined power to shock Team Rocket, which sends them blasting off once again. At sunset, Ash's group arrives in the town and succeeds in restoring the power. He is then reunited with Misty, Tracey, and Ethan.
Later, at the Pokémon Center, Ash is thanked by Nurse Joy and Officer Jenny for his help and is also asked by Ethan to join him in his job. Ash declines, saying that he would rather beat the Orange League. They leave the town and head onward for Trovita.