In the ending of Rogue One, Jyn, Cassian and the rest of the team die on Scarif so the stolen Death Star plans can reach Princess Leia, setting up Star Wars (1977).
Why does it matter that the plans escape? Star Wars (1977) begins with the Empire hunting for exactly these plans, so the ending of Rogue One is the setup for that opening. In our view, the film earns its bleak finish by making the sacrifice concrete: Chirrut, Baze and Bodhi die during the raid, the Rebel fleet arrives to help, and two Star Destroyers are crashed together to bring down the planet's shield. Jyn and Cassian then send the plans to the fleet, which is the only outcome that matters to the larger story.
The Darth Vader corridor sequence is the other piece that rewards a close read. He storms the Rebel command ship and cuts through the soldiers, yet he cannot stop the plans passing to a smaller ship. It could be argued that this is the film's central irony, because the Empire's strongest figure arrives a moment too late. Leia's line that the plans carry hope also echoes the weakness Galen hid in the weapon, so the hope in the final scene traces back to a father's quiet sabotage. Perhaps the cleanest way to see it is that Rogue One ends on a loss that the next film in chronological order, Star Wars (1977), then redeems.
Read scene by scene, the last act works as a relay in which no one carries the plans the whole way. Bodhi, Chirrut and Baze fall during the raid on the vault, the fleet breaks the shield by crashing two Star Destroyers together, Jyn and Cassian transmit the plans to the fleet, and a Death Star blast kills Krennic before it reaches the two leads as they embrace. Only then does the film cut to Vader's attack on the flagship and the handoff to Leia. Each stage is completed by a different character, and none of them is the person who started the mission, which is why the ending reads as a collective act and not a single hero's win.
Production context supports reading the ending as a late-shaped piece of work. According to the Rogue One entry on Wikipedia, Tony Gilroy directed several weeks of reshoots from June 2016, rewrote parts of the film and received screenplay credit. The entry does not say which scenes the reshoots changed, so the ending cannot be credited to any one writer. The same entry says Michael Giacchino replaced Alexandre Desplat in September 2016 with about four and a half weeks to write the score, and that Scarif was shot at Laamu Atoll in the Maldives, which means the beach where the final battle plays out is a real location and not a studio set. Leia's brief appearance, with Ingvild Deila on set and Carrie Fisher's likeness superimposed, is the most direct visual link to the 1977 film.
Comparison with the rest of the series is where the ending stands out. Rogue One is a spin-off, ninth in release order and sixth in chronological order, placed after Solo: A Star Wars Story in story order and directly before the 1977 film, so its final scene hands over to another film's opening. It was released after Star Wars: The Force Awakens and before Star Wars: The Last Jedi. In our opinion, the 1977 film treats the Death Star as a target to be destroyed, while Rogue One treats it as a cost already paid by people the later films never mention.
Why was Rogue One so good? That is a matter of opinion, and ours rests on structure rather than praise. The film gives a 15-name billed ensemble distinct jobs across three set pieces: the destruction of Jedha City, Galen's death on Eadu and the Scarif raid. Its ending delivers on a promise the 1977 film made years earlier. Audiences turned out in large numbers too: Box Office Mojo lists a worldwide gross of $1.06 billion.