Germany will deploy extra police to protect mosques, railway stations, airports and other sensitive sites because of a "very high" far-right threat following the Hanau killings, the interior minister says.
Horst Seehofer said he had agreed the measures with regional leaders, to prevent any copycat attacks.
Prosecutors say the suspected gunman, now dead, was "deeply racist".
Nine people were killed in shisha bars in the western city on Wednesday.
"The security threat from right-wing extremism, anti-Semitism and racism is very high," Mr Seehofer said. He called it "the biggest security threat facing Germany".
Muhammed B, a wounded survivor, described from his hospital bed how the gunman took careful aim at the victims in the Arena Bar & Cafe.
"Everyone he saw, he just shot them straight in the head. He laid down, then he fired at all of us. I hid behind a wall, and as I was moving to hide he shot me in the arm," he told a Turkish TV interviewer.
"It was a bloodbath... We were all lying on top of each other. The guy lying under me had a hole in his neck, he said 'I can't breathe, I can't feel my tongue'," Muhammad recalled through tears. He said he told the young man to recite a final prayer, which he did.
Who were the victims?
Investigators say all the shisha bar victims were of immigrant origin - some were German nationals, while Turkey says at least five had Turkish citizenship. Several were reported to be ethnic Kurds.
The dead also included one person each from Bosnia-Herzegovina, Bulgaria and Romania.
Tens of thousands of people attended vigils for the victims on Thursday night, in Hanau and Berlin, carrying candles and white roses in silence.
The attack, attributed to a 43-year-old German named Tobias R, is being treated as an act of terrorism.
In her response to the attack Chancellor Angela Merkel condemned the "poison of racism".
What happened in the shootings?
The shootings began around 22:00 (21:00 GMT) on Wednesday, and the first target was the Midnight shisha bar in Hanau.
The suspect then travelled by car to the Kesselstadt neighbourhood, some 2.5km (1.5 miles) away, and opened fire at the Arena Bar & Cafe.
Shisha bars are places where people gather to smoke a pipe known as shisha or hookah. Traditionally found in Middle Eastern and Asian countries, they are also popular in many other parts of the world.
Police identified the gunman through information from witnesses and surveillance cameras. Early on Thursday, they stormed the suspect's apartment, near the scene of the second shooting.
The suspect and his 72-year-old mother were found, both also shot. A gun was found next to the suspect's body.
The investigation is now focusing on whether others knew about or helped organise the attack. The suspect may have had far-right contacts in Germany or abroad.
Ali Can, a German-Turkish anti-racism activist, posted a photo of a friend of his cousin, saying that the friend was among those killed.
Writing on Twitter he said: "We can't spend a peaceful evening out, we're scared for our lives. What is happening in Germany? Where is the protection?"
What is known about the suspect?
Tobias R had posted videos and a kind of manifesto on his website, the federal prosecutor said.
In the document he wrote that people from more than 20 countries including Turkey and Israel should be "destroyed", AFP reported.
London-based German counter-terrorism expert Peter Neumann said the text contained "various, but mostly extreme right views, with a do-it-yourself ideology cobbled together out of parts found on the internet".
Hesse state Interior Minister Peter Beuth said the suspect had not previously been known to the authorities.
The Bild tabloid reports he had a firearms licence, and that ammunition and gun magazines were found in his car.
Gun laws in Germany are among the most stringent in the world, and were tightened further in recent years after other mass shootings.
BDST: 1824 HRS, FEB 21, 2020