From Wikipedia:
Miley Stewart and her best friend Lilly Truscott arrive at a concert and race backstage just in time for Miley to perform as her secret alter ego: superstar pop singer Hannah Montana. After filming a music video for her song “The Best of Both Worlds”, Miley – as Hannah – is confronted by Oswald Granger, an unscrupulous tabloid reporter. Hannah’s manager Vita sends Oswald away, but he manages to record her alluding to Hannah’s “secret”, which he becomes determined to uncover.
While shopping as Hannah, Miley fights with Tyra Banks over a pair of shoes, making her late for Lilly’s birthday party. Oswald records the incident and follows her to the party, forcing Miley to attend as Hannah in order to prevent him from learning her secret. Her arrival as Hannah steals the entire party’s attention, as does her performance of “Let’s Get Crazy”. Hurt, Lilly leaves and is questioned by Oswald. She tells him that Hannah is from Crowley Corners, Tennessee.
Already upset with Miley for prioritizing her celebrity life as Hannah over her family and friends, her father Robby is infuriated when her fight with Tyra makes headlines. He allows Vita to book a private jet for Miley to attend an awards show as Hannah, but instead flies her to Crowley Corners for her Grandma Ruby’s birthday. Forced to spend two weeks in her hometown, Miley is eager to return to life as Hannah, but Ruby chastises her for seeming to prefer being Hannah over spending time with her family.
Miley gradually reconnects with small-town life, her grandmother, and her childhood friend Travis Brody, while Robby is drawn to a local woman named Lorelai. Oswald arrives, and Miley is forced to misdirect him by claiming to know Hannah. The town holds a fundraiser to prevent developer Mr. Bradley from turning local land into a shopping mall, organizing a barn party with performances by Robby and Taylor Swift, and Miley sings “Hoedown Throwdown” as herself. When Mr. Bradley tells the crowd they will never raise enough money, Travis suggests Miley ask Hannah to hold a concert, unaware that Miley is Hannah.
Vita arrives with Lilly, who is disguised as Hannah to throw off Oswald. Miley and Lilly reconcile, and Travis asks Miley out on a date, but she has already been invited by Lorelai to a dinner as Hannah with the town’s mayor. Miley tries to be in both places at once, running back and forth between both dinners, but Travis catches her mid-change and deduces her secret. Angry that Miley deceived him, he leaves, while Robby rejects Lorelai to protect his daughter’s double-life. Miley finishes writing “Butterfly Fly Away”, which she and her father sing together. She stays up all night to complete the chicken coop she and Travis were building; touched by this, he rides to the concert.
As the town prepares for the concert, Miley receives her late mother’s necklace from Ruby. The concert begins, but Miley stops mid-song when she sees Travis and Lorelai in the audience. Explaining that she can no longer live a lie, Miley removes her blonde wig, revealing her true identity to the crowd. She sings “The Climb", and the crowd pleads with her to continue being Hannah, promising to keep her secret. Oswald takes a picture of Miley, and is confronted by her friends and family. Before he can send it, his daughters arrive – flown to the concert by Vita – and their enthusiasm for Hannah convinces him not to sell the story; instead, he rebukes his editor Lucinda and quits. Miley reconciles with and kisses Travis and returns to the stage to finish the concert with "You'll Always Find Your Way Back Home", as Lorelai and Robby reunite. During the credits, the cast dances to “Hoedown Throwdown”.