The Man Who Was Never Born, directed by Leonard Horn.
An astronaut of 1963 slips through the time barrier and finds that Earth of 2148 is desolate with the mutated, horribly disfigured human race nearing extinction. Atomic war? No: an alien microbe altered with unwise genetic manipulation.
He decides to take the gentle if hideous future man Andro back in time to persuade humanity not to do that. Problem: it seems you can cross the time barrier only once and our astronaut doesn't make it. Andro must complete the mission alone: prevent the military scientist from causing the catastrophe. Kill him if necessary.
Andro has special hypnotic powers: he can appear as the exotically handsome Martin Landau, allowing him to mix with humans of the past. Terminator (1984)-like, he has arrived too early and falls in love with the mother of the man he has to stop. Andro is both Kyle Reese and the Terminator Model 101 in one!
The setup for an SF action plot turns into a love triangle. Love triumphs because Andro is not a killer. But love also changes the future, which ought to be a happy ending, except: you can cross the time barrier only once. Andro can't return to the future, leaving Noelle alone in the space capsule...
Which is a shocking finale: we shift to an obvious sound stage, and then pull back as she drifts alone in a star field, fading out, lost in space.
That's bleak.
Another reason they can't be together: having changed the future, Andro no longer exists. As explained by the title.
This is another of my favorite, most memorable episodes, although I did not recall so much love triangle. The dialogue sometimes has a lecturing tone, like Rod Serling would use in his Twilight Zone scripts.
Conrad Hall uses soft lenses for a dream-like, fairy tale effect on Earth of 1963.
Notes:
It is a Beauty and the Beast story, with something of the Princess and the Frog. Shirley Knight as Noelle is a golden girl.
Another Star Trek analogue: The City on the Edge of Forever.
The groom sees his runaway bride blast off with a space alien on their wedding day. Did he and the groomsmen go down to the bar and talk it out afterwards?
The lens filtering produces amazing eye reflections in our lovers; I've never seen anything like it. Screen grabs don't show the effect, but it is spectacular (literaly) on the Blu-ray.
I want to mention William A. Fraker, who often operated the camera for Conrad Hall, and did this and 14 other episodes. Fraker was a cinematographer in his own right -- Rosemary's Baby (1968), Bullitt (1968), Exorcist II: The Heretic (1977), 1941 (1979), WarGames (1983) -- and a director -- Monte Walsh (1970).
The commentary track is by Gary Gerani, who gives good production detail but tends to narrate the plot.