Prolog: During the preparations for the birthday party at the beginning of The Lord of the Rings: The Fellowship of the Ring
, the elderly Bilbo Baggins (Ian Holm
) is writing a memoir. He describes the fabulously wealthy dwarven kingdom of Erebor and its relations with the human kingdom of Dale and the wood elves ruled by Thranduil (Lee Pace
). The dwarves are ruled by Thror (Jeffrey Thomas
), the King under the Mountain, and the neighboring leaders pay homage to Thror.
Dwarves, elves, and men prosper. The caves under Erebor, rich in gold and jewels are mined for an uncountable horde of riches. The dwarves find the Arkenstone, their most valued jewel, which Thror displays above his throne. One day Thror's kingdom is attacked by a dragon, Smaug. Smaug destroys much of Dale and makes short work of Erebor's defenses, despite the brave and canny leadership of Thror's grandson Thorin (Richard Armitage
). The surviving dwarves flee and Thorin is embittered when their erstwhile ally, the elven king Thranduil, declines to help them.
The dwarves attempt to reconquer Moria, another dwarven kingdom that's been overrun by evil creatures called Orcs. Led by a huge, pale Orc called Azog (Manu Bennett
), the Orcs repel the dwarves; in the battle, Azog beheads Thror and casts his head aside. An enraged Thorin attacks Azog. Losing his shield early in the duel, Thorin uses an oak log to defend himself, earning the nickname "Oakenshield." He disables Azog by severing his arm, leaving him to be pulled away kicking and screaming by some Orc soldiers. Thrain is grief-stricken by the loss of his father and goes missing, never to be seen again. (Eventually he's taken prisoner by the Necromancer.) Spurred on by the defeat of Azog, the dwarves manage to reclaim their land, albeit at the cost of the majority of their numbers. Thorin is left in charge of what is left his grandfather's empire. With nowhere to go, the dwarves scatter to make their way in the world as miners, smiths, and toymakers.
At this point Bilbo, having filled in the history leading up to his own appearance in the narrative, decides to tell his nephew Frodo (Elijah Wood
) the whole story of his adventure 60 years earlier.
One morning in the Shire, a much younger Bilbo (Martin Freeman
) sits smoking outside his front door when along comes a tallish fellow -- not a hobbit -- in a pointed hat and grey cloak. He's the wizard Gandalf the Grey (Ian McKellen
), and he's looking to enlist the last member of an expedition ready to head off on a quest. Bilbo wants no part of any adventure, but Gandalf has other ideas. As Bilbo sits down to eat the next evening, he's interrupted by a visitor, an imposing dwarf called Dwalin (Graham McTavish
) who acts as though he's expected. He wolfs down Bilbo's supper before more dwarves arrive -- Balin (Ken Stott
), Bifur (William Kircher
), Bofur (James Nesbitt
), Bombur (Stephen Hunter
), Fili (Dean O'Gorman
), Kili (Aidan Turner
), Oin (John Callen
), Gloin (Peter Hambleton
), Nori (Jed Brophy
), Dori (Mark Hadlow
), and Ori (Adam Brown
) -- as well as Gandalf and eventually Thorin Oakenshield. They carry all the food out of the pantry, rearrange the furniture, and sing a silly song to tease poor Bilbo ("Chip the glasses and crack the plates! That's what Bilbo Baggins hates!") before settling down to the business they came to discuss: their quest.
The dwarves plan to return to Erebor and reclaim their kingdom and their treasure from the dragon. A 13-member expedition invites bad luck, so they wish to hire a 14th member, a burglar -- and Gandalf assures them that Bilbo is a first-rate burglar, or will be when the time comes. Their contract offers Bilbo a 1/14th share of any profits. When Bilbo wakes up in the morning the dwarves have all gone, but Thorin has signed the contract. Bilbo catches up with them on the road and is given a pony to ride. His adventure has begun, although he's still set in his comfortable ways, and complains about the pony rub causing him a skin sore, and even trying to return to his hole in the ground.
Thorin and company travel east for some days until one evening, while puzzling over the disappearance of some of their ponies, Bilbo, Fili, and Kili (the two youngest dwarves) see firelight in the distance. They creep closer and discover three large trolls. Bilbo as the "Burglar" is pushed forward to rescue four ponies being kept in a corral. He sneaks in but is captured, the other dwarves storm to attack soon the trolls have them all bundled up. Bilbo manages to stall for time by telling the trolls the dwarves are infected. Suddenly Gandalf appears, splits a boulder with his staff and the sunlight turns the trolls to stone. Gandalf and the dwarves find some good Elven swords in the nearby cave. Gandalf gives one to Bilbo saying it will glow blue when there are orcs and goblins around.
One of the dwarves reports the ponies have all run off. Radagast the Brown shows up with his rabbit drawn sleigh. He tells Gandalf there is evil in the forest and old abandoned elf fortress. He recounts a fight with a spirit and gives Gandalf an object wrapped in cloth.
The orcs arrive and Radagast says he will lead them away, he takes off with his rabbit sleigh. The travelling party make their way while the orcs chase the brown wizard. But one orc tracks them down. The fight draws the others. Gandalf leads them into a deep crevice in the rocks, the orcs are driven off by riders on horseback, elves.
Travelling through the cave the party come out over Rivendell, Thorin angrily declares this was Gandalf's plan all along. Elrond appears with his riders and greets Gandalf and the dwarves warmly. Gandalf convinces Thorin to show the map. Elrond notices it has to be read on the same calendar day and same half moon as when it was written, which luckily today is the day. Blue letters glow on the map under the moonlight, Elrond translates the instructions on how to find the entrance to the Lonely Mountain. They need to be in a certain spot in late summer and the sun will show the door.
Later, Gandalf meets with Saruman. Galadriel and Elrond. They discuss the necromancer and some looming portents of evil. Gandalf produces the object wrapped in cloth, it is an evil sword, a Morgul blade, that was supposed to have been buried deep in a mountain. Galadriel silently promises aid to Gandalf when needed. Meanwhile the dwarves and Bilbo continue their journey.
Climbing a mountain they are suddenly caught in between a battle as the huge rocks come alive and start fighting each other, they all manage to survive and take refuge in a cave. Thorin berates Bilbo again for having to save his life, at night Bilbo prepares to sneak away. In the distance the orcs come their way. Just as Bilbo's sword glows blue the floor opens up and the party falls down a chute onto a wooden deck, they are surrounded and taken prisoner by goblins.
Bilbo manages to slip away in the confusion but has to fight a lone goblin, the two fall further into the abyss. While the dwarves are brought before the giant goblin king , Bilbo awakens to see Gollum attacking the unconscious goblin. Gollum drops a gold ring and Bilbo puts it in his pocket. A short time late Gollum discovers the hobbit and alternatively threatens and wheedles as Bilbo points his sword at him. They agree on a contest of riddles, if Bilbo wins Gollum will show him the way out, if Bilbo loses Gollum will eat him.
At the goblins the King notices the dwarves swords and recoils from the sight of the "goblin cleaver", he orders the dwarves killed. As the goblins move in suddenly there is a large white burst and everyone is stunned. Gandalf appears and urges the dwarves to run. They gather their swords and rush down the rickety wooden paths in an exciting and physics defying chase.
Bilbo and Gollum trade wits and Bilbo has the final riddle, he asks Gollum what he has in his pocket. Gollum is enraged and refuses to uphold the deal. Bilbo slips the ring on his finger and is surprised that he has become invisible to Gollum. Gandalf and the dwarves reach the bottom and run past Bilbo and Gollum. Bilbo has a chance to kill Gollum but relents and just jumps over him. Gollum is further enraged.
The dwarves make it out to a wooded area and relax, Gandalf counts heads and notices Bilbo is missing. No one knows where he is, Thorin suspects he ran off. Suddenly Bilbo appears and all are a happy.
The wargs appear and chase the group to the edge of a cliff, they all climb trees but the snarling beasts cut the branches and topple the trees. Gandalf catches a butterfly and whispers to it, releases it. Azog appears on his white warg, Thorin is stunned to see him still alive. Gandalf starts sending pine cone fireballs at the enemy below, soon the area is in flames and the animals retreat. Cornered, Thorin decides to attack and rushes toward Azog. But he is knocked down and close to death, suddenly Bilbo joins in the counterattack, saving Thorin from death. The other dwarves follow. The orcs start to gain the upper hand when a flock of huge eagles arrives and start tossing the orcs off the cliff and taking away the dwarves. Finally the last tree topples but Gandalf is saved by an eagle, the flock carries the group to the top of safe mountain. Thorin revives and is grateful to Bilbo and apologizes for doubting him. They look in the distance to the Lonely Mountain.
A thrush flies toward the gates of the old dwarf redoubt and bangs on a nut. Inside the dragon arouses from a pile of gold coins.