Will Ferrell will reunite with former "Anchorman" co-star Steve Carell for a multi-episode story arc on "The Office" that leads into Carell's farewell from the series.

Ferrell will play a branch manager from the home office who shares some of the inappropriate traits of Carell's Michael Scott. Deadline.com first reported the news.

"We found Steve Carell when he was nothing but a movie star and we turned him into a television star,” joked executive producer Paul Lieberstein. “We are proud to continue ‘The Office's’ tradition of discovering famous talent, and we hope that once America gets a good look at Will, they'll see what we see: tremendous raw sexuality.”

Fellow "Anchorman" alum David Koechner has already recurred on "The Office" as salesman Todd Packer since its earliest days.

Follow @Variety on Twitter for breaking news, reviews and more