A class of poly(ionic liquid) microgels exhibiting CO2-switchable temperature-responsive volume phase transition behavior have been synthesized and used for CO2 fixation.