"As a committed Whovian, I cannot believe my luck in joining the Twelfth Doctor for one of his inaugural adventures," Miller said in a statement. "My only worry is that they'll make me leave the set when I'm not filming."
Miller achieved fame as half of comedy duo Armstrong and Miller, alongside Alexander Armstrong, before he found success in small-screen dramas, such as Primeval and Death in Paradise.
Although Armstrong appeared in the 2011 Doctor Who Christmas special, this will be Miller’s first guest spot on the show.
Peter Capaldi recently began playing the latest incarnation of the titular time-traveler on Doctor Who, replacing outgoing star Matt Smith.
"Mark Gatiss has written us a storming villain for his new episode, and with Capaldi in the TARDIS, we knew we needed somebody special to send everybody behind the sofa," Steven Moffat, the show’s lead writer and executive producer, said in a statement. "And quite frankly, it's about time Ben Miller was in Doctor Who."