“The Last Man” episode twenty of season four of Stargate: Atlantis.
After Teyla was kidnapped by Michael and the team failed to recover her in the previous episode, “The Kindred: Part 2”, they are waiting to hear from the Genii as to where she is.
Colonel Sheppard steps through a stargate to return to Atlantis, but he returns to an Atlantis that is empty, powered down, and partially buried in a desert lit by a dying sun.
He is greeted by a hologram of a much older Dr. McKay – it turns out he has been transported thousands of years into the future. Not the first, or the last, time this has happened in the Stargate series.
There are lots of scenes from McKay’s past, about how Michael managed to take control of the galaxy. Without these it would have been a pretty short episode.
The episode shows that they still can’t age people using make-up in a way that is actually believable.
The story continues in season five and “Search and Rescue”.