Pesticide and heavy metal pollution in water can cause environmental and public health issues. Here, the authors report thermoresponsive magnetic nanorobots that can efficiently pick up and dispose of pollutants from water by adjusting the water temperature.