Donald Trump has arrived in Dayton, Ohio, at the start of a visit to the sites of two mass shootings at the weekend which left 31 people dead.
He will travel on to the Texan city of El Paso, where Hispanic people were targeted in an apparent hate crime.
Earlier, he said he was concerned about “the rise of any group of hate… whether it’s white supremacy” or any “other kind of supremacy”.
But he himself has been accused of stoking hatred against Hispanic people.
The Democratic congresswoman who represents El Paso, Veronica Escobar, is refusing to meet him, saying his “racist and hateful words & actions” had caused pain to her community and her country.
The El Paso shooting is being treated as a possible hate crime. Much of the city identifies as Hispanic and the suspect is thought to be the author of a text posted online which said “this attack is a response to the Hispanic invasion of Texas”.
The text echoed some of the US president’s language, with Mr Trump having frequently used the term “invasion” to describe the situation on the US-Mexico border.
Police have still to establish a conclusive motive for the Dayton attack but say they have uncovered evidence “that the shooter was exploring violent ideologies”.
Attempts by Mr Trump and others to link the shootings to mental illness have been criticised by healthcare professionals.
On Wednesday, the president said he did not “want guns in the hands of sick people” and was “looking to do background checks”.
He could face protests in Dayton where Mayor Nan Whaley, a Democrat, has urged people to “stand up”.
In El Paso, Beto O’Rourke, a native of the city and Democratic presidential hopeful, said Mr Trump had “no place” there.
Both he and Ms Escobar have said they will attend a community event intended to honour those who died and “confront white supremacy”.
In a tweet on Tuesday night, the president mocked Mr O’Rourke’s Spanish nickname, “Beto” and suggested he should “be quiet”. The Irish congressman’s birth name is Robert, but he was given the nickname as a child as he has the same name as his grandfather.
El Paso’s Republican Mayor, Dee Margo, said it was his “formal duty” to welcome Mr Trump but added he would “continue to challenge any harmful and inaccurate statements made about El Paso”.
Mr Trump this year inaccurately described El Paso as one of the most dangerous cities in the US as he sought to advance his border wall scheme.
By Anthony Zurcher, BBC News
In the face of tragedy, the American public has come to expect US presidents to serve as “consoler in chief” – soothing the nation’s frayed nerves and giving voice to its grief.
This is a relatively new role for the American chief executive, made possible in part by the ease of modern travel and the spread of mass media. It’s also a role with which the current president has sometimes struggled.
By now the pattern is familiar. After a mass shooting or other tragedy, Mr Trump gives a televised speech, complete with references to religious scripture, expressions of sympathy for the affected and praise for first responders.
Then, in the following days, the off-the-cuff president – the one who loves firing off tweets, riffing to crowds at campaign rallies and giving impromptu press conferences – undermines his scripted rhetoric.
After Charlottesville, the president described some among the crowd of the torch-bearing white supremacists as “very fine people”. During a photo op in hurricane-ravaged Puerto Rico, Mr Trump glibly tossed paper towels at an aid station and feuded with the territory’s public officials.
Mr Trump has notable political abilities – ones that have allowed him to rocket to the highest office in the US. He has yet to demonstrate, however, that public displays of empathy are a reliable part of his skill set.
In a speech on Monday, he said: “In one voice, our nation must condemn racism, bigotry and white supremacy.
“These sinister ideologies must be defeated,” he added. “Hate has no place in America.”
As well as advocating mental health gun control reforms, he called for the death penalty for those who committed mass murder and more bi-partisan co-operation over gun laws.
White House spokesman Hogan Gidley said it was “ridiculous” to blame Mr Trump for the El Paso shooting, adding, “You have to blame the people here who pulled the trigger.”
“Mental illness and hatred pull the trigger, not the gun,” Mr Trump said in his speech on Monday.
Calling for a reform of mental health laws, he called mass killers “mentally ill monsters”.
Texas Governor Greg Abbott, a fellow Republican, said after the El Paso attack that mental health was a “large contributor to any type of violence or shooting violence”.
In a statement condemning the gun attacks, the American Psychiatric Association warned against stigmatising mentally ill people .
“It is important to note that the overwhelming majority of people with mental illness are not violent and far more likely to be victims of violent crime than perpetrators of violence,” it said.
“Rhetoric that argues otherwise will further stigmatise and interfere with people accessing needed treatment. Individuals can also be emboldened to act violently by the public discourse and divisive rhetoric.”
In El Paso on Saturday a gunman opened fire in a crowded Walmart, killing 22 people and injuring 24 more.
A suspect, named by US media as Patrick Crusius, was arrested at the scene shortly after.
The 21-year old has been charged with capital murder, meaning he could face the death penalty.
Just hours later in Dayton, shooting began in an area popular for its nightlife.
Police killed the gunman, 24-year-old Connor Betts, within 30 seconds of him opening fire but that was long enough for him to kill nine people.
Among the dead was Betts’s sister, Megan. CCTV footage obtained by CNN showed the two drinking together at a nearby bar a couple of hours before the shooting began.