The film begins with Nick Fury, the director of the espionage team S.H.I.E.L.D visiting a research facility. While there, he comes across the Tesseract, an unknown energy within has become active and opened a portal through space. Loki, whom has been exiled, steps through the portal and attacks the people in the base. He manages to steal the Tesseract and mind control several members of S.H.I.E.L.D which included agent Clint Barton ( Hawkeye) and the physicist consultant Dr. Erik Selvig who help aid in his escape.
Due to this attack, Nick Fury activates the Avengers Initiative, against the wishes of the Boards members, which enables him to recruit members to help aid him. Phil Coulson calls upon agent Natasha Romanoff ( Black Widow) to recruit Dr. Bruce Banner in India while he sends Philip Coulson to request that Tony Stark ( Iron Man) help review Selvig’s research. Nick Fury decides to approach Steve Rogers ( Captain America) himself to give him the assignment of retrieving the Tesseract from Loki and ensuring that it is back in safe hands, even though he accepts he also states that the Tessract should have been left at the bottom of the ocean.
Meanwhile, Loki meets the Other again, an alien creature he met during his exile from Asgard. The Other offers Loki an exchange for the Tesseract; an army of Chitauri aliens that would help him take over Earth. Steve and Natasha make their way to Germany to capture Loki, who is trying to recover iridium which is needed to stabilize the Tesseract’s power and make everyone obey him, after what seems to be an impossible fight for Captain America, Iron Man comes along to fight Loki. After battling both Iron Man and Captain America, Loki surrenders and is taken back to a S.H.I.E.L.D plane to be apprehended.
As the three and S.H.I.E.L.D are escorting Loki, Thor the God of Thunder and Loki’s brother, attempts to free him so he can reason with him and take him back to Asgard, as well as the Tesseract. However, Iron Man and Thor engage in a battle that is stopped by Captain America, who persuades Thor to give up and reason with them. Loki is eventually returned to the Hellicarrier, a flying S.H.I.E.L.D air craft. Loki is placed in a cell, which was designed to hold The Hulk, so he can be questioned later about his plans.
The Avengers team come to blows with each other over how to approach Loki and what to do with the Tesseract and the recent revelation that S.H.I.E.L.D planned to use the Tesseract’s power to develop nuclear weapons. Fury explains that the events in New Mexico a year prior made S.H.I.E.L.D aware of alien life and some of which may see Earth as a target. The decision was to produce weapons with the Tesseract's energy in hopes of defending Earth should the need arise.
As the group continue to squabble amongst each other, Hawkeye leads a team of possessed agents to attack the Helicarrier. They manage to disable its engines while in the air and the Hellicarrier beings to fall. However, Iron Man and Captain America attempt to restart the engines, while Banner transforms into the Hulk despite Black Widow’s attempt to calm him down and runs amok inside the ship, leading into a battle with Thor.
Black Widow comes into conflict with Hawkeye and discovers that a blow to the head, powerful to knock him out, is strong enough to break Loki’s control. During all of the commotion, Loki manages to break free and kill Agent Coulson as well as ejecting Thor off the ship. Fury uses the death of Agent Coulson to motivate the Avengers in to working as a team. Iron Man and Captain America come to the conclusion that they must defeat Loki publically as to validate himself as ruler of Earth.
Using a device built by Selvig, powered by the Stark Tower, Loki manages to open a portal to over Manhattan, which summons a Chitauri invasion in to New York. The Avengers come to defend New York, but realize that they are becoming overwhelmed as continuous swarms of Chitauri attack Earth. The team formulate a plan to rescue civilians while Bruce Banner returns in time, and transforms into the Hulk again to attack the Chitauri invasion. Eventually the Hulk manages to confront Loki and beats him into submission.
Black Widow manages to make her way to the portal device where she finds Selvig, free of Loki’s control. He explains that Loki’s staff can be used to close the portal. Meanwhile, S.H.I.E.L.D Board members decide to attempt an end to the invasion by lauching a nuclear missile at Manhattan, despite Fury being against this action. Iron Man detects the missile and instead of destroying it in mid air he guides it in through the portal to the Chitauri fleet where it detonates. Iron Man plummets back to Earth but the Hulk catches him. Later on Nick Fury agrees to the terms laid out by Thor, to take Loki and the Tesseract back to Asgard, The Avengers watch Thor escort Loki with the Tesseract back to Asgard. After all the chaos is resolved, Fury explains that the Avengers will go their separate ways until a new threat on Earth occurs again.
During the post credit scene The Other tells his master of the outcome in which the master turns around grinning and revealing himself as Thanos.