# The City on the Edge of Forever

"The City on the Edge of Forever" is the twenty-eighth and penultimate episode of the first season of the American science fiction television series Star Trek. It was written by Harlan Ellison; contributors to and/or editors of the script included Steven W. Carabatsos, D. C. Fontana and Gene L. Coon. Gene Roddenberry made the final re-write. The episode was directed by Joseph Pevney and first aired on NBC on April 6, 1967.
In the episode, Doctor Leonard McCoy (DeForest Kelley) accidentally overdoses himself with a dangerous drug. He transports himself down to a mysterious planet while not in his right mind and is pursued by a rescue party led by Captain Kirk (William Shatner) and Spock (Leonard Nimoy), who soon come across the Guardian of Forever, a sentient time portal. McCoy travels back in time while impaired and changes history to such an extent that the Federation of Planets no longer exists. Kirk and Spock follow him to Depression-era New York City to attempt to fix the damage. While in the past, Kirk falls in love with Edith Keeler (Joan Collins), a soup kitchen operator who dreams of a future much like his own 23rd Century. Spock eventually discovers that McCoy had changed the course of history by saving Keeler from dying in a traffic collision. Much to his personal grief, Kirk allows the crash to take place, restoring history.
The episode received widespread critical acclaim and is frequently considered among the best episodes of the Star Trek franchise. Elements such as the tragic ending were highlighted by several reviewers. It won several awards, including the Writers Guild of America Award for Best Episodic Drama on Television (Ellison, 1967) and the Hugo Award for Best Dramatic Presentation (Ellison and Pevney, 1968).

## Plot

While the USS Enterprise orbits a mysterious planet causing time distortions, Chief Medical Officer Leonard McCoy is treating a near-death Lt. Sulu when the Enterprise is rocked by another time wave and McCoy accidentally injects himself with a huge dose of cordrazine, a dangerous drug. Driven into a mad frenzy, McCoy flees from the bridge and beams himself down to the planet. Captain James T. Kirk follows with a search party that includes first officer Mr. Spock, chief engineer Mr. Scott, and communications officer Lt. Uhura. On the planet's surface, they come across an ancient glowing ring which turns out to be a sentient object called the "Guardian of Forever", a portal capable of sending them to any time and place. The Guardian offers to send them back to Earth's past and plays a series of images of historical times which Spock records on his tricorder for research purposes. While the others are distracted, the still-frenzied Dr. McCoy bursts out from his hiding place and jumps through the portal. The landing party instantly loses contact with the Enterprise, and the Guardian explains that McCoy has altered the past to such an extent that the Enterprise and the reality they knew no longer exists.
The Guardian says that it's possible to fix the damage, so Kirk requests that it replay the historical period it was showing when McCoy passed through. He and Spock attempt to jump through at a point in time just before McCoy's arrival and find themselves in New York City in 1930 during the Great Depression. They steal clothes from a fire escape to blend in, and while fleeing from a policeman, hide in the basement of the 21st Street Mission. There they meet the soup kitchen's operator, Edith Keeler. She senses something odd about the intruders but nevertheless offers to pay them to clean up the basement and finds them a place to stay. Later, Spock attempts to discover how McCoy changed history by accessing the recordings on his tricorder. This is a difficult task using the available technology of 1930, which Spock likens to "stone knives and bear skins". While Spock works on the engineering problem, Kirk pays their expenses by doing odd jobs at the mission, where he falls in love with Keeler.
Unknown to Kirk and Spock, McCoy finally arrives in a highly agitated state and stumbles into the mission, where Keeler nurses him back to health. Spock completes his work and discovers that Keeler was supposed to die in a traffic collision but was somehow saved by the arrival of McCoy, creating an altered timeline in which she founded a pacifist movement on the eve of World War II. It grew powerful enough to cause the United States to delay its entrance into the war, allowing Nazi Germany time to develop the first atomic bomb and use it to win the war instead of the Allies and conquer the world. Kirk is shaken by this revelation and admits he is in love with her. Spock coldly responds that Keeler must die, in order to prevent millions of deaths and restore their future.
While walking to a Clark Gable movie with Kirk the following evening, Keeler casually mentions McCoy's name. Shocked, Kirk tells Keeler to stay right there while he crosses the street back to the mission to inform Spock. McCoy emerges from the mission at the same time, and the trio reunite on the sidewalk. Observing this, Keeler begins to cross the street to join them and does not notice an oncoming truck. Kirk instinctively turns to save her, but a shout from Spock freezes him in his tracks, and Kirk reluctantly grabs McCoy so he can't save her either. Keeler is struck and killed. A stunned McCoy asks Kirk if he knows what he just did, but it is Spock who replies, "He knows, Doctor. He knows."
Kirk, Spock, and McCoy return through the Guardian and rejoin the landing party, where they find the Enterprise and their timeline is fully restored. As they transport back to the ship, a grim-looking Kirk ignores questions about what happened, replying simply, "Let's get the hell out of here."

## Production
### Writing

The writing of this episode took over ten months, from the initial pitch by Harlan Ellison to the final re-write by Gene Roddenberry. Steven W. Carabatsos and D. C. Fontana, both story editors on the show, undertook re-writes of the teleplay, and changes have also been attributed to producer Gene L. Coon. The experience led to animosity between Ellison and Roddenberry for the rest of the latter's life, in particular over a dubious claim by Roddenberry that Ellison had the character Scotty dealing drugs in one version of the script. The episode went over budget by more than $50,000 and overran the production schedule. Mistakes were made in the set design with an instruction for "runes" misconstrued as a request for "ruins". With Matt Jefferies ill, Rolland Brooks designed the set and the Guardian of Forever, to the surprise of Jefferies on his return.

#### Initial pitch and outlines

Harlan Ellison was one of the first writers recruited by Gene Roddenberry for Star Trek. Roddenberry was aiming to have the best science-fiction writers produce scripts for the show and had identified Ellison immediately. At the time, Ellison had been nominated for the 1965 Writers Guild of America Award for Outstanding Script for a Television Anthology with his script for the Outer Limits episode "Demon with a Glass Hand"; he went on to win. Rather than being assigned a pre-written premise, Ellison was allowed to develop his own and propose it in a 10-page outline. Ellison had read a biography of evangelist Aimee Semple McPherson, and thought that it would be an interesting idea to have Kirk travel back in time and fall in love with a similar woman of good intent, but someone who must die in order to preserve the future. Ellison considered that it would have a heartrending effect on Kirk.
In March 1966, Ellison pitched the idea to Roddenberry, who accepted it. A week later, he turned in his first script treatment. Producer Robert H. Justman later recalled that he thought it was brilliant. When writing it, Ellison did not have as many restrictions as some of the later writers; he was hired prior to the series bible being created. The first version introduced Lieutenant Richard Beckwith, who is sentenced to death after he kills a fellow crewman when he is threatened with the exposure of his involvement in the illegal drug trade. Ellison had included this element, since he expected the starship to be like any other military unit, having at least some unlawful people. Beckwith is then escorted to the surface of a nearby planet alongside Kirk, with Spock to carry out the execution by firing squad. Because of the planet's atmosphere, they have to wear environmental suits. On arriving, they find an ancient civilization and the remains of a city — this was Ellison's "city on the edge of forever". It is inhabited by several 9-foot-tall (2.7 m) men, the Guardians of Forever, who protect an ancient time machine.
Kirk then asks to see the history of the United States on the machine, and as it reaches the Great Depression of the 1930s, Beckwith dives into the projection and vanishes. The guardians inform Kirk that history has been altered, and upon returning to the Enterprise, they discover that the vessel is now crewed by renegades. They fight their way back to the transporter room and return to the planet, where the Guardians allow Kirk and Spock to pursue Beckwith into the past. They are informed by the Guardians that Beckwith prevented the death of Edith Koestler, and as in the final version, Kirk falls in love with her; in this version, however, he does so knowing that she must die in the end. Emotionally, he cannot stop Beckwith from attempting to save Koestler – Spock has to do it. Roddenberry had asked for the ship specifically to be placed in danger, and so Ellison added the renegade element in response. Beckwith is captured but again escapes into the projection and ends up in an endless loop of an exploding Nova sun – he screams, and dies forever without end.
Roddenberry disagreed with some of Kirk's actions in the first draft, and he asked Ellison to rewrite the treatment without pay. The redraft took a further five weeks, after which Roddenberry gave more notes and Ellison took another two weeks to respond. When a version was received on May 13, Roddenberry and the executives at Desilu and NBC were all relieved—there had been concerns over the amount of time taken, as scripts were being pitched, written, and approved in the time taken for Ellison to revise his outline. This version dropped the environmental suits due to cost, and rewrote the information given to Kirk by the Guardians, making it more general and less Earth-specific. It also changed Edith Koestler's surname to Keeler. However, the majority of the plot points were unchanged.

#### Development of the teleplay

Justman registered immediate concerns over the potential cost of attempting to film the treatment. He had particular concerns about a time portal effect, a scene involving a mammoth and the number of exterior and night shoots that would be required. Despite this, Roddenberry asked Ellison to turn it into a shooting script and set aside a desk for him in the assistant director's room, expecting him to attend the office every day until he finished it. Ellison ended up with a smaller office of his own at his request but disliked it sufficiently that he spent the majority of his time on set. He would play loud rock and roll music in the office, and then leave it for the set. On one occasion story editor John D. F. Black caught him on set during the filming of "Mudd's Women" and had him escorted back to the office. The music went on, and Black went back to tell Ellison to turn it down, but the writer had already climbed out the window and left. On other occasions, he worked late into the night and slept on the couch in Justman's office. As the delays added up, the slots assigned to "The City on the Edge of Forever" were reallocated to other episodes. Although this period was later claimed to be of various lengths, Ellison completed the first draft teleplay in three weeks, handing it to Justman on June 7. Black later said that Ellison always had "40 things going" in reference to him doing multiple assignments at once. In response, Ellison said that doing multiple assignments at the same time was simply how screenwriters earned a living in the 1960s.
Justman's initial glee at receiving the script was short-lived. He realized quickly that it was unfilmable due to cost, and the characters were not behaving as per the writer's guide. One such exchange between Kirk and Spock had the Vulcan character accusing humans of being barbaric, while Kirk saying Spock was ungrateful because humans were more advanced than Vulcans. Justman thought it was a good script, but could never be re-written and filmed in time for the first season. Ellison was asked to revise it once more, with the problems blamed on requests from NBC, and submitted a further version a week later. The production team was starting to lose patience, as he was not revising it in accordance to their requests, and he began arguing with Justman over the budget difficulties. On August 15 Ellison turned in a second revised draft to Justman, titled "final draft" on the front cover. Justman wrote a memo immediately to fellow producer Gene L. Coon, saying that after five months, Ellison had failed to reduce the budget requirements for the episode to something that could be filmed.
Roddenberry and Justman both spoke to Ellison, seeking further changes, but failed to convince him. William Shatner was sent to Ellison's house to try to get the writer to reconcile. He claimed he was shouted at and thrown off the property, but Ellison said that Shatner had read the script through while sitting on a couch and had left to tell Roddenberry that he liked it. Ellison suggested that Shatner had a personal interest in having the script revised because Leonard Nimoy had more lines than he did in Ellison's version, and had spent the time on the couch counting lines. Meanwhile, Steve Carabatsos replaced Black as story editor on the show and was told by Coon to fix the script. Carabatsos replaced the new characters with an accident involving McCoy and an overdose of adrenalin and removed the Guardians of Forever, replacing them with a time travel portal. Ellison subsequently accused him of "taking a chainsaw" to the script. Roddenberry disliked the new version sufficiently that he convinced Ellison to come back and rewrite it again.
On December 19 Ellison submitted a further revised teleplay, dated December 1. Justman suggested in a memo that Roddenberry might be able to rewrite the latest version to one that could be usable. He said that although it was a "fine story" and Ellison was an "extremely talented writer", he felt that it needed to be either rewritten by someone else or scrapped altogether. Taking this advice in hand, Roddenberry rewrote the script over the Christmas–New Year period, handing in a new version on January 9, 1967. His changes included the elimination of the evil version of the Enterprise and the addition of some comedy elements. Justman was pleased with Roddenberry's changes and told Coon that it was close to being filmable but that he still expected it to exceed the budget for a single episode.
Dorothy Fontana was hired as a new story editor, replacing Carabatsos. She had previously been Roddenberry's secretary and was well aware of the script's problems from reading the previous versions. When she arrived at work for her first day in her new role, Roddenberry gave her a copy of his revision and told her to try rewriting it. She later referred to that day as "walking into a hornets' nest", and the script itself as a "live grenade". Among the changes in her version was the introduction of the drug cordrazine. Ellison specifically criticized this change, as his most recent version of the script called for an alien creature's venom to cause the symptoms in McCoy. He said that "Gene [Roddenberry] preferred having an accomplished surgeon act in such a boneheaded manner that he injects himself with a deadly drug!"
Justman praised Fontana's version, saying that it was the version that was most likely to be shot. But he suggested that it had now lost the "beauty and mystery inherent in the screenplay as Harlan originally wrote it". He said that he felt bad, because if he had not seen Ellison's earlier versions then he would probably have been "thrilled" with Fontana's version. Still unsatisfied with the script, Roddenberry set about rewriting it once more, titling the result, dated February 1, the final draft. Ellison later called elements of the dialogue in this version "precisely the kind of dopey Utopian bullshit that Roddenberry loved", and added that Roddenberry had "about as much writing ability as the lowest industry hack". Shatner later came to believe that it was actually re-written by Gene L. Coon and only supervised by Roddenberry. Ellison requested via his agent that he be credited on the script only as Cordwainer Bird. In response, Roddenberry threatened to have Ellison blacklisted by the Writers Guild of America, and the writer was eventually convinced to be credited by name. None of the other writers involved in the work chose to seek credit for the script, since they agreed with Roddenberry that it was important for Star Trek to be associated with writers such as Ellison.

### Direction and casting

Joseph Pevney was assigned as the director of this episode. He had previous experience in directing full-length films, and later explained that "The City on the Edge of Forever" was the closest episode in Star Trek to that same level of work and challenge, stating that he treated it as a film. But he was critical of Ellison's version of the script, saying that he "had no sense of theater" and it was fortunate that Roddenberry re-wrote it. He praised Ellison's level of detail in the 1930s setting, and for the general idea behind the episode.
The crew were surprised when actress Joan Collins expressed an interest in appearing in the series. After her agent asked her if she wanted to appear on the show, Collins, who had never heard of it, mentioned it to her children. When her oldest daughter was enthusiastic about the show, Collins decided to accept the offer from the studio. Casting director Joe D'Agosta called her a "notorious actress", but said that at the time they saw approaches from a wide range of actors and actresses who wanted to appear on the series. Pevney said "Joan Collins was very good in it. She enjoyed working on the show and Bill and Leonard were both very good to her.... Using her was a good choice." Collins later incorrectly recalled Keeler as a Nazi sympathiser, an error that has been repeated in biographies of the actress. Ellison said in response that this was not an intended character trait.
John Harmon appeared as a hobo in "The City on the Edge of Forever" and returned in a more prominent role in "A Piece of the Action". Although some sources have credited the voice of the Guardian to James Doohan, it was actually performed by Bartell LaRue. The actor later appeared onscreen in the episode "Bread and Circuses", and provided further voiceover work in "The Gamesters of Triskelion", "Patterns of Force" and "The Savage Curtain". Also returning to Star Trek in this episode were David L. Ross as Lt. Galloway and John Winston as Lt. Kyle.

### Filming and post production

Filming began on February 3, 1967, with an expectation that it would take six days to film. The shoot was completed a day and a half behind schedule on February 14. The overall cost was $245,316, compared to the budget of $191,000 for this episode. The normal budget for episodes during the first season were $185,000. Roddenberry later claimed that around $257,000 was spent on the episode, and said that he could have saved a further $20,000 if he had not insisted on high-quality casting and sets. He also claimed that the original Ellison version would have cost a further $200,000 on top of what was already spent.
The shoot began on location at the Desilu Forty Acres, with Pevney aiming to complete all the location filming in a single day in order to complete the episode in the allocated six days. The site had been used previously for the episodes "Miri" and "The Return of the Archons". None of the producers expected him to do so, but with the series already $74,507 in the red and with two more episodes left to film, Desilu had to appear to NBC to be trying to keep to budget. Extensive work was completed during the daylight hours, on the set that had been used for other series such as The Andy Griffith Show, with Floyd's barbershop appearing in some of the shots. The filming continued into the night, and with Pevney running out of time, he was not sure when to stop. The problem was that other series such as Rango and Gomer Pyle had the sets booked up for the next several days, and they were unsure whether they would have time to return and film the missing scenes.
After a weekend break, filming resumed on the Desilu Gower Street sets, where My Three Sons was normally shot. These were used to represent the interior of the mission where Keeler nurses McCoy back to health. DeForest Kelley felt that McCoy should also fall for Keeler; so Pevney shot the scenes with that element included but never included it in the final cut. The following two days were spent on the same sets, while on day 5 the action moved to the bridge set for the Enterprise. This day's shoot was meant to include scenes in the transporter room and in the Enterprise corridors, but by now the production was a full day behind and these were pushed to the following day. Partway through day 6, the filming moved to a neighboring set for the exterior ruin shots and the Guardian of Forever, which was used for the next two and a half days. The montage of historical footage was all taken from the Paramount film library, as was the footage of the Brooklyn Bridge.
Harlan Ellison long maintained that the ancient ruins were the result of someone's misreading his description in the script of the city as "covered with runes". When informed that the word "runes" did not appear in any version of his treatments or script (or any rewrites), Ellison responded in Edge Words, the letter column of IDW's comic book adaptation of his original script, by admitting that his memory was faulty and that he actually told Matt Jefferies that the set should appear "Ancient, incredibly ancient, with runes everywhere..." He surmises that he perhaps slurred the word "runes" and Jefferies misheard him.

### Music

There are a number of musical pieces reused from earlier episodes in "The City on the Edge of Forever", including sufficient use of the scores from "The Cage", "Where No Man Has Gone Before" and "The Naked Time" that Alexander Courage received an "additional music by" credit. Further pieces came from "Shore Leave", "Charlie X" and "The Enemy Within". A partial score was created by Fred Steiner, his final work of the first season. His work on Star Trek tended to focus on the use of violins and cellos to highlight romantic moments, and he did not use violas in any of his works on the series. This episode originally featured the 1931 song "Goodnight Sweetheart", which was originally composed by Ray Noble with lyrics by Jimmy Campbell and Reg Connelly. For the version used in the episode, the lyrics were recorded by an unknown session musician.
It had been licensed to appear in the episode, and at first, Steiner sought to use motifs from "Goodnight, Sweetheart" as the basis of his score. He wanted this to be subtle and introduce the melody of the song over time, but Justman realized what Steiner was attempting and rejected it on the basis that he did not want the song introduced too early in the episode. Another work of Steiner's that was rejected for "The City on the Edge of Forever" was an alternative main title track using saxophone and celesta, which he had hoped would set the episode in the tone of the 1930s. The music recorded specifically for "The City on the Edge of Forever" was recorded in stereo, which was unusual for the series. This was rediscovered when a 15-disc soundtrack of The Original Series was being compiled by La-La Land Records, which they hypothesized was because the accompanying vocals appeared on a separate track.
By the time "The City on the Edge of Forever" was released in the 1980s for home media use, such as on VHS and Laserdisc, the license for the use of "Goodnight, Sweetheart" had lapsed and was instead picked up by a different studio. A new score was composed to replace the song where it was used in the episode; however, the new pieces did not match the existing Steiner works as they used a different orchestral arrangement. Steiner was not contacted or informed of the changes to the soundtrack requirements, and this was instead composed by J. Peter Robinson. The original intention was not to restore "Goodnight, Sweetheart" to the DVD release, and issue the DVD with a disclaimer on the box, "Some music has been changed for this DVD." However, the original "Goodnight, Sweetheart" portion was erroneously included and Paramount reportedly had to pay royalties. Since the royalties had been paid, all subsequent releases have included the original "Goodnight, Sweetheart" music and with the 1980s scores omitted.

## Reception
### Broadcast

"The City on the Edge of Forever" was first broadcast in the United States on April 6, 1967, on NBC. A 12-city overnight Trendex report compiled by Nielsen ratings showed that during the first half-hour, it held second place in the ratings behind Bewitched on ABC with 11.64 million viewers compared to Bewitched's 15.04 million. The episode beat My Three Sons on CBS. During the second half-hour it remained in second place with 28.4 percent of the audience share, behind the 32.1 percent for Love on a Rooftop, also on ABC.
A high-definition remastering of "The City on the Edge of Forever", which introduced new special effects and starship exteriors as well as enhanced music and audio, was shown for the first time on October 7, 2006, in broadcast syndication in the United States. It was the fifth remastered episode to be shown. This meant that the episode was made available to over 200 local stations across the United States with the rights to broadcast Star Trek, and depending on the station it was broadcast either on October 7 or 8.

### Cast and crew response

This episode has been held in high regard by those who have worked on Star Trek. Roddenberry ranked it as one of his 10 favorite episodes, and said it was his favorite alongside "The Menagerie" and the second pilot, "Where No Man Has Gone Before". In the final interview before he died, he said it was his favorite outright. Fontana said it was one of her two favorite episodes that she was not credited for, along with "The Trouble with Tribbles".
Members of the main cast have also said it was among their favorites. Shatner has often chosen either this or "The Devil in the Dark" as the best episode, saying, "'City' is my favorite of the original Star Trek series because of the fact it is a beautiful love story, well told." Nimoy described it as one of his favorites, along with "The Devil in the Dark", "Amok Time", "Journey to Babel", "This Side of Paradise" and "The Naked Time". In his 1995 book, I Am Spock, Nimoy said that episodes such as "The City on the Edge of Forever" and "Amok Time" were "just as powerful and meaningful to today's audiences as they were to viewers back in the 1960s". Kelley said it was his favorite, adding, "I thought it was one of the most dramatic endings ever seen on a television show." Karl Urban, who plays McCoy in the 2009 Star Trek and the sequels, said that "The City on the Edge of Forever" was one of his favorite episodes along with "The Corbomite Maneuver", "Amok Time" and "Arena".

### Critical acclaim

"The City on the Edge of Forever" has been frequently cited as the best episode of all the Star Trek series and movies. In a preview of the episode in the Albuquerque Journal, it was said to be a "surprise variation of the 'time tunnel' theme" and was described as "an absorbing tale, a bit hard to take at times, but imaginative nonetheless". After Star Trek IV: The Voyage Home, in which time travel was an integral part of the plot, was released in 1986, Luis Aguilar of The Washington Post said that "The City on the Edge of Forever" was superior to the film, calling it a "brilliant, beautifully executed story".
For the franchise's 30th anniversary, it was ranked as the best Star Trek episode. "The City on the Edge of Forever" has placed highly in many "best of" lists of Star Trek episodes. In a special edition of Entertainment Weekly during the fall of 1994, "The City on the Edge of Forever" was ranked number one in a comprehensive listing of all 79 episodes. The article described the episode as "Cosmic themes, effective acting, and a heart-wrenching ending makes this the undisputed Uber-Trek". In 2021, Screen Rant ranked it as the second best episode of the original Star Trek series to re-watch. A ranking of every episode of the original series by Hollywood.com also placed it number 1 calling it "Star Trek’s greatest episode"

#### 2000s onwards

In their 2003 book, Beyond the Final Frontier: An Unauthorised Review of Star Trek, Mark Jones and Lance Parkin described "The City on the Edge of Forever" as "Rightly regarded as the highlight of original Star Trek" and the "epitome of what Star Trek does best". They said that having Kirk allow Keeler to die was "horrifying and heart-rending, adding another dimension to his character".
Zack Handlen of The A.V. Club gave the episode an 'A' rating in 2009, describing it as "a justly revered classic". But he said that McCoy's accidental overdose was a "stretch" and gave the episode "a surprisingly awkward start, with little indication of the greatness that is to follow". He called the ending "brutal" and praised the conundrum that Kirk is placed in, faced with the death of Keeler. Handlen suggested that it would have made a better final episode of the season, instead of "Operation: Annihilate". Also in 2009, it was reviewed by Torie Atkinson and Eugene Myers for Tor.com, where they gave it a rating of six out of six. They were concerned that the episode might not live up to the memory when they re-watched it, but said "it remains an incredible episode, often imitated but rarely surpassed in science fiction in any medium." They said that both the tragic and comedic moments helped to balance the episode, and said that the ending was abrupt but fitting because of the change in Kirk despite the Guardian's announcement of "all is as it was before".
Keith DeCandido gave the episode a rating of ten out of ten when he reviewed it for Tor.com in 2015. He said that the episode centered on people, which he saw as a common theme among the great episodes of Star Trek. DeCandido supported the view of Spock, that while Keeler's compassionate nature was to be applauded, it was at the wrong time and as war with Nazi Germany was the only way. Darren Franich compared "The City on the Edge of Forever" to the 12 Monkeys television series in 2015, calling the episode "one of the great episodes of television". However, he criticised it as well, saying "complete crock of pseudo-scientific claptrap. It's wacky like only old science-fiction is wacky – and it's slow like only old television is slow." He listed nine "leaps of narrative logic" that a viewer must overcome to accept the plot. But he felt that it was fearless in comparison to modern science fiction, in that there was no attempt to make it self-aware, nor introduce a comedic character to ground it. Franich said that the ending was "one of the all-time great moments in Star Trek history".
IGN ranked it as number one out of their "Top 10 Classic Star Trek Episodes" in 2009. It said "This beautiful story poignantly establishes the maxim later explored in Star Trek II: The Wrath of Khan: the needs of the many outweigh the needs of the few, or the one. Kirk's reaction before beaming up at the end of the episode is one of William Shatner's most moving moments in all of Trek." In the Radio Times, David Brown listed it as the second best episode for non-Star Trek fans to watch on Netflix in 2016, calling it a "tragic Back to the Future" and that "seeing as the bulk of the drama takes place during the depression of the 1930s, there's not much in the way of sci-fi gubbins to confuse a newcomer". Jeremy Fuster at Yahoo! TV included it on a list of ten episodes to watch prior to the launch of the 2017 television series, calling it "one of the most heartbreaking episodes" of the series.
In 2009, while writing for Time Magazine, John Cloud rated "The City on the Edge of Forever " as one of the top ten moments of Star Trek overall including films up to that time. Cloud noted "The City on the Edge of Forever" as "a tightly wound episode that sets the standard for time-travel sci-fi". Specific elements of the episode led to other rankings, such as Comic Book Resources (CBR) placing it as the tenth-best romantic relationship of the Star Trek franchise up to that time, between Kirk and Edith Keeler. In a listing of the best time-travel episode of all Star Trek series by CBR, it was placed first; it was placed in the same position on a similar list by Nerdist.
The episode remained popular throughout the 2010s, with British Magazine SciFiNow ranking it as the best episode of The Original Series in 2010. The A.V. Club called it one of the top ten "must see" episodes in 2012, as did Newsweek in 2016. It was named as one of the 25 essential episodes of the franchise by Vox in 2016. In 2017, Business Insider ranked "The City on the Edge of Forever" the second best episode of the original series; as did PopMatters a year later.

### Awards

Harlan Ellison's original version of the teleplay won the annual Writers Guild of America Award for Best Episodic Drama on Television. Justman later said that the submission of the original unfilmed version was out of spite, and Roddenberry said in response to the victory "many people would get prizes if they wrote scripts that budgeted out to three times the show's cost." The WGA rules allow only the credited writers to submit scripts for consideration, who may submit whichever draft of theirs that they may choose. It was up against another Star Trek episode, nominated by the production team; "The Return of the Archons". Coon reportedly said at the time: "If Harlan wins, I'm going to die", and that "there are two scripts up tonight for the Writers' Guild Award, and I wrote them both." On that night, Roddenberry and several of the crew were seated at a table that Desilu had purchased, while Ellison was at another. When he won, the Star Trek party rose to their feet and applauded, since they believed it would bring credibility to the series. Herbert Franklin Solow later recalled that this elation turned to horror when Ellison began talking about the interference of studio executives in the writing process, before holding aloft a copy of the original script and yelling "Remember, never let them rewrite you!" Ellison walked past the Desilu table as he left the podium, and shook the copy of the script at Roddenberry and his party.
When Glen A. Larson claimed that it was Coon who had rewritten the original script and it was this version that was submitted to the Writer's Guild, Ellison said that "pandas will fly out of Glen Larson's ass!". He explained that as the credited writer, he had the option of which version of the script to submit to the Guild. A further claim was made by writer Don Ingalls, who said that Ellison had admitted in a drunken stupor to him late one night in a bar that he had tidied up and improved the script further prior to submitting it; this was then published in Justman and Solow's Inside Star Trek: The Real Story. Ellison repudiated Ingalls' claim, pointing out that he never drank since he did not like the taste and had never been drunk and so this could not have occurred. Upon being informed, Solow promised to add a note refuting the claim in a future paperback edition, but then decided to agree with Ingalls' version of the story.
"The City on the Edge of Forever" was awarded the Hugo Award in 1968 for the "Best Dramatic Presentation" at that year's World Science Fiction Convention. This was based on the filmed version, and not Ellison's original. But since the script remained credited to Ellison, he won the award once more. It was 25 years before another "Star Trek" television program won that award again, the next occasion being for the episode "The Inner Light" from Star Trek: The Next Generation. Roddenberry later claimed that he was present at the Hugo Awards, and said that Ellison rushed past him up onto the stage. However, he was not present. Ellison remarked afterwards when talking about the Hugo win for the filmed version of the script, "I would like to be arrogant enough to think that the script was so good that even butchering it couldn't hurt it" and that compared to the other episodes of Star Trek that it was "a pretty good show". Roddenberry claimed, in response to Ellison's awards wins for the episode, that he had won a Nebula Award for his work on it. However, this was untrue, and the Dramatic Presentation category was not created until 1974.

## Home media release and other adaptations

The first adaptation of "The City on the Edge of Forever" was as a re-working into a short story by author James Blish in the novel Star Trek 2. He attempted to combine elements of both the televised version with aspects of Ellison's original version after being sent a copy of the original script by Ellison. The front cover of the British release of the book featured the Guardian of Forever. This was republished in 2016 alongside the Blish short stories of 44 other episodes in a single volume as Star Trek: The Classic Episodes. The first home media release of "The City on the Edge of Forever" was on Compact Cassette from Startone productions in 1982. A LaserDisc of the episode, alongside "The Alternative Factor" was released in 1985. Further releases of all episodes of the series were made on VHS and Betamax.
"The City on the Edge of Forever" was released on DVD paired with "Errand of Mercy" as part of the general release of the series in 2000, and as part of the season one DVD set in 2004. The episode was included in the remastered season one release on DVD and Blu-ray in 2009. The remastered version included revamped and expanded special effects by CBS Digital under the guidance of Dave Rossi, as well as Mike and Denise Okuda. Changes included an expanded field of ruins on the Guardian's planet, as well as updated visuals of the planet from space. Rossi explained that they sought to tie the purple cloth backdrop used in the original version into the redesign, but was concerned that the "giant purplish desert flats" as seen from space were instead misconstrued as oceans. "The City on the Edge of Forever" was also featured in several DVD sets featuring compilations of episodes, including the Star Trek: Fan Collective: Captain's Log, as selected by Shatner, and Captain Kirk's Boldest Missions in 2015.

## Legacy
### Ellison–Roddenberry feud

During the period in which the script was being developed, Roddenberry asked Ellison for his help in saving the show. In response, Ellison agreed with other science fiction writers, including Richard Matheson, Theodore Sturgeon and Frank Herbert to form "The Committee". Ellison wrote on their behalf to the combined membership of the recent World Science Fiction Convention to ask them to write in to NBC to save the show. Shatner later credited Ellison for saving the show during the first season. But after the work was completed on the episode, Roddenberry and Ellison did not speak for several years. Ellison said he felt used, while Roddenberry said he was being unfair and had unjustly condemned the episode, loudly and in public. Ellison sold copies of his original script at conventions, while Roddenberry's Lincoln Enterprises sold the filmed version. In 1975, Ellison copyrighted the version of the first draft script as it was returned to him with notes, which was then published in Six Science Fiction Plays by Simon & Schuster. By this time, he and Roddenberry had taken conciliatory steps toward each other, and he was invited to pitch a story idea for a late 1970s Star Trek film, despite calling Star Trek "dead" in an interview with The Washington Post when the film project was first announced.
This did not last. Roddenberry claimed in an interview with Video Review magazine that Ellison wrote into the script that he had Scotty dealing drugs and when asked to remove it, Ellison claimed that Roddenberry had "sold out". At no point in any of the versions of the outlines or scripts did Scotty deal or take drugs. Roddenberry repeated this claim around the same period in 1987, including to Ben Harnson in an interview for Cinefantastique magazine, and on the convention lecture circuit. Two issues later, writer Alan Brennert wrote into the letters page of Video Review asserting that Scotty had never sold drugs in any version of the script. In response, Roddenberry wrote to Brennert, dated March 25, 1987, and admitted to mistakenly attributing the drug dealing to Scotty. Despite this, other publications have repeated the incorrect claim by Roddenberry. Roddenberry also claimed to have created the Edith Keeler character and based her on his father, a police officer, in an interview with Humanist magazine in March 1991.
Until approached by TV Guide in December 1994, Ellison did not discuss the issues with the episode in print other than the introduction in Six Science Fiction Plays. He was reluctant to discuss it for the magazine, and to make them go away, asked for a sum of money he believed was five times more than the magazine had ever paid for an interview. To his surprise, the magazine agreed. So he wrote the article, which immediately generated a backlash from Star Trek fans.
In his 1996 book, Harlan Ellison's The City on the Edge of Forever, Ellison claimed to have never received more than a "pittance" from working on the episode. He said "every thug and studio putz and semi-literate bandwagon-jumper and merchandiser has grown fat as a maggot in a corpse off what I created." He said that was the reason why he wrote the book. On March 13, 2009, Ellison filed a lawsuit against CBS Television Studios, seeking 25% of net receipts from merchandising, publishing and other income from the episode since 1967; the suit also named the Writers Guild of America for repeatedly failing to act on Ellison's behalf on the matter. In a press statement, Ellison said, "It ain't about the 'principle,' friend, it's about the money! Pay me! I'm doing it for the 35-year-long disrespect and the money!" On October 22, 2009, the lawsuit was settled with Ellison claiming he was satisfied with the outcome.

### Guardian of Forever

The Guardian of Forever, the time portal portrayed in the original series episode, is an irregular ring (or torus) shaped structure around 3 metres (9.8 ft) wide. The Guardian's next on-screen appearance was in the Star Trek: The Animated Series episode "Yesteryear" (1973), in which the Guardian's voice was provided by James Doohan (who portrays Chief Engineer Montgomery Scott).
A return for the Guardian in The Next Generation was proposed by Trent Christopher Ganino and Eric A. Stillwell during the writing of the episode "Yesterday's Enterprise". This would have seen a team of Vulcan scientists led by Sarek studying the Guardian, and accidentally travelling back in time to the history of their planet where they cause the death of Surak, the founder of Vulcan logic. After they return, they discover that their people had allied with the Romulans and were at war with the Federation. In response, Sarek elects to return to the past and take on the role of Surak to restore the timeline. Producer Michael Piller wanted the plot to be centered on the cast of The Next Generation, so Sarek and the Guardian were dropped from the story.
The Guardian returned in the third season of Star Trek: Discovery in the two-part story "Terra Firma" episodes 9–10. In those episodes, the Guardian has relocated itself to another planet, Dannus V, to prevent itself from being weaponized in the Temporal Wars. It also has the ability to project a humanoid avatar, named Carl (Paul Guilfoyle), which it uses to hide its true nature until it trusts any individuals that encounter it. The Guardian tests Philippa Georgiou before sending her back to a time that she can survive in.

#### Non-canonical novels and short stories

The Guardian of Forever has also appeared in several Star Trek novels. The first appearance was in Star Trek: The New Voyages, a 1976 compilation of short stories that was the first anthology of Star Trek fiction. The short story "Mind Sifter" by Shirley S. Maiewski saw Captain Kirk stranded on 1950s Earth in a mental hospital, having been abducted by Kor, subjected to a Klingon mind sifter, and transported through the Guardian of Forever. In A.C. Crispin's 1983 novel Yesterday's Son, the Guardian is used by Kirk, Spock and McCoy to visit Sarpeidon in the past from the episode "All Our Yesterdays". There they discover that the subject of Spock's romantic liaison, Zarabeth, had died years before but she had given birth to his son, Zar. An audio recording by Nimoy and George Takei was subsequently released. After the success of the book, Crispin was asked to write a sequel, Time for Yesterday in 1988, in which the Guardian is malfunctioning and the Enterprise crew must seek the help of Zar to communicate and repair it.
Peter David decided to base his 1992 novel Imzadi on the same premise as the end of Ellison's version of "The City on the Edge of Forever", except in this case it was William Riker who went back in time using the Guardian deliberately to save the life of Deanna Troi. He felt that if Ellison was not allowed to use the idea in the episode, he could instead feature the premise in a novel. The Guardian was also central to the plot of Judith and Garfield Reeves-Stevens' 1994 novel Federation as it recites three historical events to Captain Kirk.
Brett Hudgins short story Guardians was featured in the seventh volume of Star Trek: Strange New Worlds in 2004, an annually published work of fan stories. In the story, the Horta from "The Devil in the Dark" colonise the Guardian's "Time Planet" and end up acting as its protectors for the following generations over the following 50,000 years. David R. George III decided to include the Guardian and spin-off from events in "The City on the Edge of Forever" in his 2006 trilogy, "Crucible." In Provenance of Shadows, the installment of the trilogy based on McCoy, part of the book is based in the reality where McCoy is trapped in the past and no-one comes to rescue him. The events of "The City on the Edge of Forever" are also recounted in the fictional The Autobiography of James T. Kirk by David A. Goodman; the author said that the effects of the episode and the loss of Keeler would affect Kirk for a long time and may have been why the character never entered into a serious ongoing relationship.

#### Non-canonical comics and computer games

In the Gold Key Comics Star Trek line, the Guardian of Forever appeared in the story "No Time Like the Past" by George Kashdan and Al McWilliams and appearing in issue 56, published October 1978. Kirk, Spock and McCoy must correct history after another traveller uses the Guardian to travel to the second century BC, and they confront both Hannibal and the Romans. In the second volume of DC Comics run of Star Trek comics, the Guardian appears in issues 53 through 57 within the story "Timecrime" by Howard Weinstein, Rod Whigham, Rob Davis, and Arne Starr.
IDW Publishing published Ellison's script as a comic book under the title of Star Trek: Harlan Ellison's Original The City On The Edge Of Forever Teleplay in 2014. Chief Creative Officer and Editor-in-Chief Chris Ryall said "Presenting Harlan Ellison's brilliant original script for 'City on the Edge' has been a goal of ours since IDW first began publishing Star Trek comics in 2007". Ellison worked alongside IDW on the comic, with artwork by J.K. Woodward and additional writing by Scott Tipton and David Tipton. Ellison said of the format, "To read a graphic novel is to engage your imagination is to engage all five of your senses and to picture what the creator dreamed. And that's what this book does for me." A reprint collection was released in 2015 (ISBN 978-1631402067).
In the massively multiplayer online role-playing game Star Trek Online, the mission "City on the Edge of Never" involved the player character using the Guardian to travel through time to 2270 to stop Klingons intent on altering history. The episode features the USS Kirk, and has the Guardian projecting a time portal into space, allowing the player to take their vessel through to the past. It featured voice acting by Nimoy and was well received by reviewers with Kotaku writer Mike Fahey saying "This mission might have just made the entire game for me. Everything about it was simply perfect. If Star Trek Online fails for some reason, this mission will always be remembered. The mission as it was is no longer available."

### "Let's get the hell out of here," Nazis, and other influences

Kirk's final line in the episode, "Let's get the hell out of here," caused problems for the crew as the network did not want the word "hell" to appear in television episodes. Both Shatner and Roddenberry fought for the line to remain, with Roddenberry claiming to NBC that no other word would be suitable to be used instead. The studio executives agreed that it could be left in, and it was one of the first occasions in which the word "hell" was used as profanity on television. The episode was also the first time that the Nazis were mentioned in Star Trek. They featured more prominently in the second-season episode "Patterns of Force" as well as a pair of two-part episodes, one each from other Trek franchises: one from Star Trek: Voyager as "The Killing Game" and the other from Star Trek: Enterprise as "Storm Front".
When a Star Trek film was being developed in the late 1970s, one of the ideas proposed by Roddenberry was to have the crew travel back to the 1960s and prevent the assassination of John F. Kennedy. This idea was based on "The City on the Edge of Forever", due to the episode's popularity among fans by that time. The episode was also suggested by Robert F. Moss in The New York Times as later influencing the plot of Star Trek IV: The Voyage Home. When Nimoy met Harve Bennett to discuss proposed plots for the film, it was Bennett's love of "The City on the Edge of Forever" that led to him suggesting that they should include a time travel element in the film. This led to the duo discussing the potential plot with Ellison. A reference to "The City on the Edge of Forever" was included in the two-part Star Trek: Deep Space Nine episode "Past Tense", with a boxing poster appearing in a scene set in the 1930s featuring Kid McCook and Mike Mason. There was a similar poster advertising a match at Madison Square Garden in "The City on the Edge of Forever", while the one in "Past Tense" stated that it was a rematch in San Francisco.

### Trading Cards

In 2020, Rittenhouse Archives Ltd. released the Star Trek The Original Series Archives and Inscriptions Trading Cards product. Included in the product was a 44-card insert set titled "Uncut The City on the Edge of Forever". The set featured scenes from the episode on the fronts and short descriptions of the action on the backs.