SG-1 arrives through the Stargate in a room filled with advanced-looking technology. They are greeted by an elderly man -- Ma'chello -- who has been hunted by the Goa'uld for many years because of his efforts to develop technology to fight them. He shows Daniel one device. But after they each grasp the handles of the strange object, Ma'chello falls down, unconscious.
The team brings the old man back to Earth, where Dr. Frasier determines that he is near death. As for Daniel, he isn't exactly acting like himself. General Hammond sends him home for the day.
Back in the infirmiry, Ma'chello has regained consciousness, and is claiming to be Daniel Jackson. He demonstrates this by answering questions only Daniel would know, and tells SG-1 that the machine has somehow switched his consciousness with Ma'chello's.
The real Ma'chello, now in the body of Daniel Jackson, wanders the streets of Colorado Springs trying to learn about Earth culture and customs. He comes upon a homeless man, Fred, and invites him to feast at a local diner. In fact, Ma'chello is anxious to celebrate his new life and his "strangeness," and invites the whole restaurant to "feast" on Daniel's credit card.
Daniel is left to die, trapped inside of Ma'chello's aged, scarred body. To try and reverse the transferrance, should Ma'chello be found, the rest of SG-1 returns to Ma'chello's planet to retrieve the device. Carter is intrigued by his technology, and hopes to find something to help her in deciphering the symbols in Ma'chello's notes.
The team's safety precautions are not enough, though: Teal'c and O'Neill switch bodies. They manage to bring the device back to the S.G.C., but Carter cannot find a way to reverse the process.
Teal'c -- or rather, O'Neill in Teal'c's body -- comes down with an illness. Teal'c must show O'Neill how to enter kelnorim -- a deep meditation -- in order to allow his Goa'uld symbiote to heal Teal'c's body. If O'Neill cannot do this, Teal'c's body will die, along with O'Neill's consciousness.
Jack is successful in reaching the deep meditation, and Teal'c's body is eventually healed. Meanwhile, local police have tracked Ma'chello to a diner through Daniel's credit card. Fred watches helplessly as they arrest his strange new friend.
At the S.G.C.'s infirmiry, Ma'chello looks upon his old body with distain, and states that he will not undo the change -- that he can't. He designed the device to encode each transferrance, so that it could not be undone.
Ma'chello tells them that he took Daniel's body because he deserves it. He has been hunted for decades, captured and tortured, and spent his whole life creating technology to fight the Goa'uld. Without his lifetime of work and sacrifice, Ma'chello says, Earth and many other worlds would have been conquered long ago. It is the least they can do, he tells them, to compensate him with a new life.
Ma'chello attempts to bargain with them, asking them to exchange Daniel's body and his freedom for all of his knowledge and technology -- with which they will be able to not only defend themselves against the Goa'uld, but perhaps even defeat them.
Hammond refuses, and Ma'chello remains under house arrest. Hammond and Carter vow that he'll spend his whole life in a tiny cell deep underground. Carter takes him to see the dying Daniel, so that Ma'chello might get to know his "casualty of war."
Daniel tells the abstinent man of Sha're, his wife, and argues for the value of his own life. Finally, he accuses Ma'chello of being a Goa'uld. The Goa'uld take human bodies as hosts because they believe they are better than humans, because they believe they deserve it. Ma'chello's actions are no different. "You're a Goa'uld, Ma'chello," Daniel states. "I am nothing but a host to you."
Ma'chello is moved by Daniel's words, and tells Carter that he would trade places with Daniel if it were possible -- but he is the only one who cannot. This gives Carter an idea. Ma'chello and O'Neill trade bodies, then Teal'c and Daniel. Jack and Daniel are then able to trade places and return to their own bodies, as are Teal'c and Ma'chello. The device would not allow Ma'chello and Daniel to trade, but would allow them to trade with the others.
With all restored, Ma'chello breathes his last words: "Thank you for my holiday."