Inside the TARDIS, the Fourth Doctor, Romana, Adric, and K9, while travelling between E-Space and the normal universe (N-Space), become trapped in a white null space between the universes. Elsewhere in the void, another spacecraft, run by Captain Rorvik, has also become trapped. The ship is a slave vessel, using members of the leonine Tharil race as their navigators. On becoming stuck, the current navigator, Biroc, escapes the ship and makes his way to the TARDIS on the winds of time. Biroc warns the TARDIS crew of Rorvik's treachery before disappearing. K9's memory wafers are shredded by the winds of time, leaving him functional but lacking long-term memories.

The Doctor leaves on his own to explore the null space, finding a large stone gateway. Beyond it is a large banquet hall, a large mirror on one of its walls, the corpses of several beings, and the husks of primitive robots strewn about. He discovers one of the robots is still functioning and asks it questions as he repairs it; the robots, called Gundans, were built by slaves and used to overthrow their masters in a violent battle.

Meanwhile, Rorvik and his crew have discovered TARDIS. Romana leaves to talk to them. Rorvik, believing Romana to be time-sensitive like the Tharils, dupes her into returning to their ship to examine their engines. When Romana does not return, Adric and K9 leave to recover her, but they get separated; Adric eventually makes it to the ship and hides aboard, while K9 reunites with the Doctor and aids in repairing the Gundan. The Doctor's work is disrupted when Rorvik and several of his men arrive and hold the Doctor at gunpoint. While they stand-off, another Gundan activates and walks through the seemingly-solid mirror. Rorvik demands an explanation from the Doctor, revealing he has Romana captive, but the Doctor's only response is to walk through the mirror himself.

Aboard the slaver ship, Romana is freed by another Tharil named Lazlo, and she hides in the hull of the ship. There, she encounters Adric; the two work out that the ship is made from an incredibly dense dwarf star alloy that can contain the Tharils. K9 arrives, and informs the two of dimensional instability in the null space, which they attribute to the alloy, causing the space to collapse in on itself. Romana rejoins Lazlo, and takes her to the gateway and through the mirror, while Adric remains aboard the slaver ship.

On the other side of the mirror, the Doctor and Romana are reunited with Biroc in a stable, time-locked universe. A repentant Biroc explains they were the slave masters, travelling on the winds of time in order to ravage other planets and subjugate their populations as slaves until the Gundan revolt. The Doctor and Romana are returned to the null space, and are immediately captured by Rorvik. Rorvik's crew has come to realise that the null space is shrinking as the distances between the gateway, the TARDIS, and slaver ship continue to decrease. Rorvik has ordered the crew to try to blast through the mirrors in gateway, believing it to be the way out, but the mirrors resist all attack by their most powerful weapons. With the gateway and ship in visible distance of each other, Rorvik resorts to one last attempt to break the mirrors by using the exhaust of the ship's engines against them. While the Doctor warns that this action will be as doomed as the previous ones, Romana is able to regroup with Lazlo and Adric, and together they free the remaining Tharils on the slaver ship. The TARDIS crew flee to the TARDIS as Rorvik initiates his plan—the blast from the engines is reflected by the mirrors back onto the ship, destroying it and its crew.

As the saved Tharils pass through the mirror, Romana announces that she will be staying with them, having become empathetic to their plight. The Doctor gives her K9, as passing through the mirror will restore his memory but he will be unable to return. The Tharils, in exchange, provide the Doctor with information on how to leave the void back to N-Space.

Originally, the fifth story of season 18 was Sealed Orders by novelist Christopher Priest before being abandoned. Stephen Gallagher, who had written a number of radio plays, was called upon for a replacement, resulting in Warriors' Gate. Commissioned in March 1980, this was Gallagher's first script for Doctor Who and had the working title Dream Time. The story was influenced by a radio serial he had done in 1979 called "The Babylon Run" as well as the films of Jean Cocteau, such as Orphée (1950), in which mirrors provide a gateway into another world.[3]

On completion in June, script editor Christopher H. Bidmead found the scripts to be overlong, as well as needing more work to keep them in line with other stories in the series. Therefore, he and director Paul Joyce re-worked the story significantly, including re-writing much of the dialogue. Originally, the script was much more comedic, with Rorvik's crew being given a lot of humorous dialogue, two of the workers being played as a double-act. Executive producer Barry Letts in particular was against this, saying that it was turning the show into pantomime and stated that the crewmen must be played for real. As many of these lines were cut from the script, the few remaining "comedy" lines were to be played straight as well. The scripts were finalised in late August 1980, but were then criticised by Letts, who found them rather confusing. By this time however, there was no more time to rework them further as Bidmead needed to begin work on the following story. Producer John Nathan-Turner too found the story complicated but had not got involved with the story during its scripting stages. Bidmead met with Gallagher with the revised scripts, the latter being none too happy with the extensive changes.[3]

Warriors' Gate was significant in that it was the last story to feature companion Romana played by Lalla Ward as well as the last regular appearance of John Leeson as long-running companion K9. Ward had requested to leave earlier, having been offered a part in another series, but Nathan-Turner kept her to her contract. It was also during the making of this serial that Tom Baker let it be known that he would leave at the end of the series.[3] Ward and Baker were in a relationship and had been for some time, but by now things were turning acrimonious between the two, with many production personnel believing that they were on the point of splitting-up. It was with much surprise when they learned that just a few weeks later they had married. Leeson, who left the series at the end of Season 16, returned for Season 18 on the understanding that K9 would be written out toward the end of the season.[4]

Joyce was keen to push the limits of the series by directing the serial like a film as he considered some of the earlier productions to be quite bland and workmanlike.[5] This approach however caused problems early on with significant delays in order to achieve various shots such as the pan through the spaceship in the opening sequence. This included shooting the camera upwards where the gallery lights could be seen - known as "shooting off set", something which is forbidden by the BBC. Problems such as this increased as time began to run short and he and producer Nathan-Turner clashed frequently and even executive producer Letts had to step in to advise Joyce. With letters being written to higher executives complaining of Joyce's style of work (also seen as inexperience), Joyce was asked to leave part way through production. His duties were taken up by assistant Graeme Harper, who directed a number of scenes before finally Joyce was re-instated.[6] Setting up of certain shots that Joyce had envisiged proved to take up too much time and shooting over-ran on a number of days.[5] In the end, the serial was completed and was indeed a departure in terms of style over the norm and was complimented by Bidmead, but Joyce was never to work on Doctor Who again.

Background photographs utilised in many sequences were taken at Powis Castle, Welshpool.[7]

A novelisation of this serial, written by Stephen Gallagher under the pseudonym "John Lydecker",[8] was published by Target Books in April 1982. It is one of only two Target novels that consists of continuous prose with no chapters. The novelisation contains many elements abandoned during the story's production, including the slaver's opening pursuit and damage at the hands of an Antonine Killer craft.

Warriors' Gate was released on VHS as part of "The E-Space Trilogy" boxed set in November 1997. It was released on DVD in January 2009, again in a boxed set entitled "The E-Space Trilogy". This serial was also released as part of the Doctor Who DVD Files (issue 87) in May 2012.