A 43-year-old German man shot and killed nine people at several locations in a Frankfurt suburb overnight in attacks that appear to have been motivated by far-right beliefs, officials said Thursday.

The gunman first attacked a hookah bar and a neighbouring cafe in central Hanau at about 10pm. Wednesday, killing several people, before heading about 2.5 kilometres west and opening fire again, first on a car and then a sports bar, claiming more victims.

Chancellor Angela Merkel said that while the circumstances of the attack still needed to be fully investigated, the shootings exposed the “poison” of racism in German society and pledged to stand up against those who seek to divide the country.

Hookah lounges are places where people gather to smoke flavoured tobacco from Middle Eastern water pipes, and some of the victims appeared to be Turkish.

Witness Kadir Kose ran over from a cafe he runs nearby after he heard the first shots, initially assuming there was an altercation between family members.

“But when I heard the second shots I thought it was a terror attack,” Kose said.

He said he was shocked at the extent of the violence, saying that while fights or stabbing aren’t unheard of, “this is a whole other level, something we hear about from America.” Witnesses and surveillance videos of the suspect’s getaway car led authorities quickly to his home, near the scene of the second attack, where he was found dead near the body of his 72-year-old mother, said Peter Beuth, the interior minister for the state of Hesse.

Neighbour Dieter Hog said he looked out his window and saw 25 or 30 police officers with dogs combing the area.

“They were running around looking for the fugitive who was involved,” Hog told The Associated Press, adding that even though he lived close by he did not know the suspect.

Both the suspect and his mother had gunshot wounds, and the weapon was found on the suspect, Beuth said.

At the townhouse Thursday, forensic experts came and went from the building, and police kept people away.

A website believed to be the suspect’s is being evaluated, Beuth said.

“Initial analysis of the web page of the suspect indicate a xenophobic motivation,” he said.

It does not appear, however, that the suspect was known either to police or Germany’s domestic intelligence agency, he added. He said federal prosecutors have taken over the investigation of the crime and are treating it as an act of domestic terrorism.

“This is an attack on our free and peaceful society,” he said.

Following a conference call with Germany’s state interior ministers, Bavarian Interior Minister Joachim Herrmann said on the basis of the investigation so far, “it was a right-radical xenophobic” attack, German news agency dpa reported.

The attack was quickly and broadly condemned by many organisations, including the Central Council of Muslims, the Confederation of Kurdish Associations in Germany, and the Central Council of Jews.

Merkel pledged that “everything will be done to investigate the circumstances of these terrible murders.”

In unusually plain words, the German leader said: “Racism is a poison. Hatred is a poison.” “This hatred exists in our society and its is responsible for far too many crimes,” she added, citing the killings committed by a far-right gang known as the NSU, the shooting of a regional politician from her party last year and the attack on a synagogue in Halle in October.

She added that authorities would do everything possible to stand up to those who try to divide the country with racism.

French President Emmanuel Macron tweeted it was a day of “immense sadness” and pledged his “full support for Germany.”

“I’m at the side of Chancellor Merkel in her fight for our values and the protection of our democracies,” he said.

Turkish Foreign Minister Mevlut Cavusoglu said the consulate in Frankfurt and the embassy in Berlin were trying to obtain information about the attack, including the possibility that some of the victims were Turkish. “According to the initial information, it was an attack with a racist motive, but we would need to wait for the (official) statement,” he told state television TRT.

German news agency dpa reported that police are examining a video the suspect may have posted online several days earlier in which he details a conspiracy theory about child abuse in the United States. The authenticity of the video couldn’t immediately be verified.

In the video, the dark-haired speaker wearing a white button-down shirt under a suit jacket, said he was delivering a “personal message to all Americans” that “your country is under control of invisible secret societies.”

In a slow and deliberate voice, in accented English, he says there are “deep underground military bases” in which “they abuse, torture and kill little children.”

He makes no reference to the far-right fringe QAnon movement in the U.S., but the missive is similar to the movement’s central, but baseless belief that U.S. President Donald Trump is waging a secret campaign against enemies in the “deep state” and a child sex trafficking ring run by satanic paedophiles and cannibals.

On a website registered by someone with the same name as the man in the video, Tobias R., the owner says he was born in Hanau in 1977 and grew up in the city, later training with a bank and completing a business degree in 2007.

The attack comes amid growing concerns about far-right violence in Germany. Merkel called off a planned visit Thursday to a university in Halle. Her spokesman, Steffen Seibert, said she was “being constantly kept abreast of the state of the investigations in Hanau.”

Halle was the site of a deadly anti-Semitic attack last year. A man expressing anti-Jewish views tried to shoot his way into a synagogue, failed and killed two passers-by before being arrested.

The shooting in Halle came months after the killing of a regional politician from Merkel’s party. The suspect had a long history of neo-Nazi activity and convictions for violent crime.

“Thoughts this morning are with the people of Hanau, in whose midst this terrible crime was committed,” Seibert said on Twitter. “Deep sympathy for the affected families, who are grieving for their dead. We hope with those wounded that they will soon recover.” In addition to those killed, Beuth said one person was seriously wounded and multiple other people suffered less serious injuries.

--- Geir Moulson and David Rising in Berlin, Michael Probst and Christoph Noelting in Hanau, and Suzan Fraser in Ankara contributed to this report. Jordans reported from Berlin.

AP