The ending of The Avengers (2012) closes the invasion plot cleanly and leaves one thread open on purpose. In my opinion, the finale works because every member of the team has a job: Stark carries the missile through the portal, the Hulk catches him on the way down, and Romanoff shuts the portal with Loki's own scepter, which the freed Selvig identified as the off switch.
Why does that scepter detail matter? Earlier, Loki used the same weapon to put Selvig and Barton under his control, so the villain's method is turned against him rather than beaten by raw force. Compare that with the first act in Stuttgart, where Loki forces a crowd to kneel and Rogers, Stark and Romanoff confront him: the film sets his power up as control over people, then answers it by giving control back, first to Barton when Romanoff frees him aboard the Helicarrier and later to Selvig.
The emotional hinge is Coulson. Clark Gregg's agent had already appeared in Iron Man (2008), Iron Man 2 and Thor, so by the time Loki kills him after escaping the Helicarrier, audiences who followed the saga in release order had spent several films with him. It could be argued that this is the payoff of the shared universe in miniature: the team's anger over that loss is what finally pulls a quarrelling group together, which a first time viewer with no earlier films would feel less sharply.
How does the finale compare with the earlier solo films? Iron Man (2008) ended on one man in one suit, and Thor (2011) left Loki exiled. Here, on a $220 million budget, Whedon needed to give six leads a share of the climax. The film has more than 2,200 visual effects shots from 14 companies, with Industrial Light & Magic as lead vendor, and Mark Ruffalo performed the Hulk through motion capture, which helps the catch of Stark feel like a character beat rather than a pure effects shot. In my opinion, that makes the 2012 film the cleaner model of a team finale, even next to Avengers: Age of Ultron.
Thor takes Loki and the Tesseract back to Asgard to answer for his crimes. That sets up the next stage for both brothers, because Thor: The Dark World finds Loki sitting in an Asgardian prison. In release order the next stop is Iron Man 3, where Stark is anxious and sleepless after the alien attack on New York and spends his nights building ever more suits. That is a direct, human consequence of this finale, and a smart way to follow it.
The open thread is the Other's master. Because the Other answers to a more powerful figure, the film promises a bigger threat than a single exiled god, and it takes until Avengers: Infinity War (2018), with Josh Brolin as Thanos, for that promise to pay off. Perhaps the most striking part is the patience: six years separate the credits tease from the payoff, and it could be argued that this is the real template for the saga's long form storytelling.