He said if cities and states failed to control the protests and "defend their residents" he would deploy the army and "quickly solve the problem for them".
Protests over the death of George Floyd are entering their seventh day.
As Mr Trump spoke at the White House, police cleared protesters from a nearby park with tear gas and rubber bullets.
The president then crossed the park and posed next to a damaged church, provoking widespread criticism from those who accused him of aggressively targeting the peaceful demonstrators in aid of a photo opportunity.
Meanwhile, dozens of major cities have imposed overnight curfews. New York City is under lockdown until 05:00 (09:00 GMT) on Tuesday and Washington DC has extended its curfew for another two nights.
But demonstrations have largely continued unabated. They began after a video showed Mr Floyd, 46, being arrested in Minneapolis on 25 May and a white police officer continuing to kneel on his neck even after he pleaded that he could not breathe.
The officer, Derek Chauvin, has been charged with third-degree murder and will appear in court next week. Three other police officers have been fired.
On Monday, an official post-mortem examination declared Mr Floyd's death a homicide.