Selective elimination of impurities