While orbiting what should be a dead planet, the U.S.S. Enterprise experiences a moment of "nonexistence." Starfleet Command fears an enemy invasion and orders Kirk to find out what caused the stellar system disturbance.
On the planet below, Kirk finds a man called Lazarus, who tells Kirk that the effect was caused by his enemy. Lazarus has been chasing him with the aid of a time/space craft and wants the Enterprise's dilithium crystals to continue his search. The captain refuses.
When Kirk takes Lazarus aboard the U.S.S. Enterprise, it becomes apparent that there is something strange about their visitor. He has incredible mood swings, one minute sane and rational, the next exhibiting violent rage. He also has a bloody head wound that disappears, then reappears moments later.
Lazarus manages to steal the ship's dilithium and return to the planet. Kirk follows and discovers that Lazarus is two people — one sane and one a madman, with one from an anti-matter universe. The sane Lazarus informs Kirk that the beings can only appear in either universe one at a time. Should both men be in the same place at the same time, both universes would be destroyed. Kirk helps the sane Lazarus trap his counterpart in an intermediate time corridor where they can hurt neither the matter nor anti-matter universe, but where the two will be trapped in fight until the end of time.