Nicholas Hoult has withdrawn from his role as Gilderoy Lockhart in the upcoming Harry Potter series for HBO, with Kit Harington stepping in to replace him. Hoult's departure comes after a significant fan backlash related to the involvement of J.K. Rowling, the author of the original book series and an executive producer on the new adaptation.

Fans expressed dismay over Hoult's casting, objecting to his participation in a production where Rowling remains involved due to her widely publicized views on transgender rights. Critics argue that supporting the series financially contributes to a franchise associated with Rowling's controversial stances.

Hoult had previously described the role as an "easy yes," telling Variety that he loved the character of Gilderoy Lockhart and found the opportunity to play him entertaining and fun. The character is known for his role as a Defense Against the Dark Arts teacher at Hogwarts, who, according to the book series, takes credit for others' achievements after altering their memories.

Kenneth Branagh originated the role in the 2002 film "Harry Potter and the Chamber of Secrets," which grossed over $883 million worldwide. Hoult is also known for portraying Lex Luthor in an upcoming Superman film and has received Emmy and Golden Globe nominations for his work in the UK series "Skins" and the Hulu comedy "The Great."

The HBO reboot of the Harry Potter series is set to premiere its first season on Christmas Day. Filming for the second season is scheduled to begin in the fall. The series features Dominic McLaughlin as Harry Potter, Alastair Stout as Ron Weasley, and Arabella Stanton as Hermione Granger, with Nick Frost as Rubeus Hagrid and John Lithgow as Albus Dumbledore. Jon Brown has been promoted to co-showrunner for the second season alongside Francesca Gardiner.

Rowling, who is executive producing the series, recently shared on X that she had read the first two episodes and found them to be "SO, SO, SO GOOD."