"We should soundly reject language coming out of the mouths of any of our leaders that feeds a climate of fear and hatred and normalizes racist sentiments; leaders who demonize those who don't look like us, or suggest that other people, including immigrants, threaten our way of life," Obama said in a press release.
Obama said that the same type of language has been the root of most human tragedy, including slavery and Jim Crow, the Holocaust, the genocide in Rwanda and ethnic cleansing in the Balkans.
"It has no place in our politics and public life," he said.
Without naming President Donald Trump by name, Obama's statement is a direct criticism of current US president's leadership style. In the wake of this weekend’s mass shootings, several Democratic lawmakers have slammed Trump for fueling the type of rhetoric that leads to such incidents.
US Congressman Eliot Engel in a tweet on Monday said that Trump cannot say Americans need to condemn hatred and racism "while simultaneously stoking hatred and racism for political gain."
On Saturday morning, dozens of people were killed when a gunman opened fire in a Walmart shopping centre in El Paso, Texas. The suspect was identified by police as 21-year-old white supremacist Patrick Crusius.
US Attorney for the Western District of Texas John Bash said the Justice Department is treating the shooting as a case of domestic terrorism.
The Office of Mexican Secretary of Foreign Affairs Marcelo Ebrard said that seven Mexican citizens were killed in the shooting in El Paso.
In another mass shooting incident on Sunday, a gunman killed nine people in Dayton, Ohio. Police said they neutralized the shooter, identified as 24-year-old Conner Betts, in less than a minute. Local authorities on Monday said there is no indication that race was a motive in the shooting.