After lengthy negotiations, Fox‘s musical dramedy Glee has been picked up for next season. And the season after that. The network has  given a two-year renewal to the series for Seasons 5 and 6. The negotiations took longer because the network starts footing the bill after Season 4. Given the complications of the talks, a two-year pickup is common practice so the network won’t have to do it again next year. Even if Glee‘s ratings continue to slip, the dramedy has an off-network syndication deal with Oxygen, which makes a longer run attractive for Fox sibling 20th TV, the studio that produces Glee with Ryan Murphy TV. Glee now joins veteran Bones, freshman drama The Following and comedies New Girl, The Mindy Project and Raising Hope, which all have been renewed for next season.

“Glee debuted as the first and only successful musical comedy series on television, and more than four years later, it continues to defy genres, break new ground and have a significant impact on popular culture,” said Fox chairman Kevin Reilly. Added 20th TV chairmen Dana Walden and Gary Newman, “Ryan, Brad, Ian and Dante have created something that is far larger than a television show; it’s a global entertainment brand which continues to touch millions around the world.” Glee was created by Ryan Murphy, Brad Falchuk and Ian Brennan, who executive produce the series with Dante Di Loreto.

While off the ratings heights from its early run, Glee still performs respectably, especially when DVR viewing is factored in. The dramedy is averaging a 3.6/10 among adults 18-49 and 8.7 million total viewers this season. Last month, Glee marked its 500th performance. The show has spawned more than 53 million tracks digitally downloaded and more than 13 million albums sold worldwide.