Production on the film, which is directed by Matthew Vaughn, is finished but McKellen will enter the sound booth to provide the narration for the film that is to be released July 27, Zap2it.com reported Tuesday.
"Stardust" features a star-studded cast that includes Claire Danes, Robert DeNiro, Michelle Pfeiffer and Charlie Cox.
The story centers on a man who is questing to retrieve a fallen star and meets witches, gnomes, goblins and all sorts of creatures along the way.
McKellen has previously worked on "Gods and Monsters," "The Lord of the Rings: The Fellowship of the Ring," "The Da Vinci Code" and "X-Men: The Last Stand."
LGBT community has 'bullied the American people': Bachmann
Attkisson leaves CBS News, reportedly over network's 'liberal bias'