ADDIS ABABA, Ethiopia—President Barack Obama excoriated Republican critics of the nuclear agreement with Iran, particularly GOP presidential candidates, saying they are playing “fast and loose” with the facts to scuttle the accord and making a mockery of the American political process.

Asked specifically about GOP presidential candidate Mike Huckabee invoking the Holocaust to criticize the Iran deal as akin to marching Israelis “to the door of the oven,” Mr. Obama said Republicans are employing political rhetoric about the...