The comment by Auckland District Court Judge David Harvey raised questions about his impartiality. He was discussing Internet copyright at a conference last week when he told an audience, "We have met the enemy, and he is U.S."
Harvey's comments referencing late cartoonist Walt Kelly were recorded and posted on the Internet.
The U.S. is attempting to extradite Dotcom on racketeering and money laundering charges that allege his file-sharing site was facilitating massive Internet piracy.
Harvey will be replaced by judge Nevin Dawson. An extradition hearing has been scheduled for March.