A gunman carried out a shooting rampage in a busy shopping area of Munich, killing at least nine people and wounding several others in an act of "suspected terrorism" before he committed suicide, police said Saturday.

The rampage prompted authorities to lock down the southern German city and launch a massive manhunt for suspected perpetrators. Police later determined that the attack at Munich's Olympia shopping complex was apparently carried out by a lone gunman and that he committed suicide about half a mile away.

The motive of the killer, who police said was an 18-year-old German-Iranian who lived in Munich, was unclear.

There were no immediate details about the victims of what a police spokesman said "looks like a terrorist attack." The Associated Press quoted Munich police spokesman Peter Beck as saying 10 people were killed in total, including the shooter.


Much of the city was placed on lockdown as police conducted their manhunt. Despite initial reports of multiple attack sites, police could not confirm attacks in any other locations besides the shopping area.

WATCH: Video shows victims inside Munich mall
READ MORE: Munich shooting, as it happened
GALLERY: Terror in Munich

Officials did not immediately specify how the attack unfolded or describe the full scope of the bloodshed at the Olympia mall.

But a senior security official told The Washington Post that four people were killed inside a McDonald's restaurant and one was fatally shot outside. The official said another victim died at a hospital.

The initial investigation was pointing "in all directions," police spokesman Marcus de Gloria Martins told reporters in Munich.

German officials said investigators were looking into the possibility that the attack might have been motivated by anti-immigrant sentiments, as well as the prospect that Islamist extremism was behind it. Language against foreigners can be heard on a recording from the scene of the shooting, but it was not immediately clear who was speaking.

A German television station said a witness told a colleague that the shooter shouted "Bloody foreigners!" at the scene of the McDonald's attack. There was no immediate confirmation of that account.

German news media reported that police found a body, possibly that of the McDonald's shooter, about a half mile from the scene and were checking a backpack for explosives.

Hours after the attack, Martins said police were still assuming that "up to three perpetrators" were involved. "We're definitely not assuming that it's more than three, but it might also be that it's fewer than that," he said.

President Obama pledged to provide Germany with whatever help it may need to investigate a deadly shooting incident. He also noted the "tough time" the US has had in recent weeks as he thanked police officers for maintaining safety.

A German intelligence official noted that it was the fifth anniversary of a lone-wolf massacre in Norway that claimed the lives of 77 people. The bomb and gun attacks there were carried out by a right-wing extremist.

As the manhunt was launched, helicopters fanned out over the city and Munich's transit system was shut down. Residents were asked to stay off the streets.

There was no immediate claim of responsibility for the rampage, but a high-ranking police official told The Post that it appeared likely that it was linked to terrorism.

A message posted online in Arabic, apparently from an Islamic State account, said: "Nowhere is safe for all of you. You people have opened the doors of hell by declaring war on us."

An elite German counterterrorism force was promptly dispatched to Munich to help deal with the situation.

An employee inside the mall, who would give only her first name, Sabiha, said she saw a gunman open fire outside her clothing store. The assailant - described as about 6-foot-1, with black hair and a beard, and wearing a black shirt and "some kind of vest" - moved through the corridors before leaving the building, she told The Post.

Sabiha said she saw at least two people killed and one injured.

"I was lucky because he shot toward the other directions, not mine," she said, speaking from a hiding spot inside a storage room in the store.

A video clip posted on Twitter showed a gunman opening fire outside a McDonald's near the shopping complex as people dashed for cover. The man appeared to fire on passersby with a handgun, seemingly at random.

A police statement sent by Twitter urged people near the site to remain in their homes.

A similar announcement was issued by the U.S. Consulate in Munich, which reported "shots fired at multiple locations in Munich." It advised U.S. citizens to "shelter in place pending police announcements that the situation is under control."

A later statement issued by the consulate said that "Munich's main railway station is closed, and mass transit remains halted."

A U.S. investment adviser and blogger, Eddy Elfenbein, tweeted Friday that his brother was in Munich. "He was helped to safety by a young Syrian immigrant. The young man's family called from Aleppo to see if he was OK," Elfenbein wrote.

In Washington, President Barack Obama told a group of law enforcement officers at the White House that the United States is offering German authorities "all the support that they may need in dealing with these circumstances," which he said remain murky.

He said the Munich attacks serve as a reminder that "our freedoms, our ability to go about our business every day, raising our kids, seeing them grow up and graduate from high school, now about to leave their dad - I'm sorry, I'm getting a little too personal, getting a little too personal there - that depends on law enforcement. It depends on the men and women in uniform every single day who are, under some of the most adverse circumstances imaginable at times, making sure to keep us safe."

In a separate statement, the White House said the United States "condemns in the strongest terms the apparent terrorist attack that has claimed innocent lives in Munich." It added: "The resolve of Germany, the United States, and the broader international community will remain unshaken in the face of acts of despicable violence such as this."

Republican presidential nominee Donald Trump said in a statement: "This cannot continue. The rise of terrorism threatens the way of life for all civilized people, and we must do everything in our power to keep it from our shores."

The Munich mall is near the city's Olympic Stadium, the centerpiece of the 1972 Summer Olympic Games that become known for tragedy when Palestinian terrorists took Israeli athletes hostage and killed 11 of them.

Munich is about 40 miles north of Germany's southern border with Austria, and the city has been deeply affected by a huge influx of refugees sparked by upheaval in the Middle East. More than 1 million asylum seekers arrived in Germany in 2015, and many of them have passed through Munich. About 1 in 7 of the arrivals remain in the city and surrounding region, in the state of Bavaria.

German security forces have been on heightened alert since Monday, when a 17-year-old Afghan armed with a knife and an ax attacked passengers on a commuter train near the Bavarian city of Würzburg. At least five people were injured.

The Islamic State claimed responsibility for the train attack, but German authorities have said there is no evidence of direct links between the teen and the group.

Last month, German authorities arrested three Syrians on suspicion of planning an Islamic State attack on the city of Düsseldorf. The men had entered Germany with a wave of migrants fleeing war and mayhem in the Middle East.

The alleged plot involved suicide bombers, firearms and explosives, German authorities said. The arrests potentially thwarted a deadly operation comparable to assaults on Brussels in March and Paris in November.