A gunman believed to have been inspired by far-right ideology has killed six people and injured more than a dozen others in an attack in the busy centre of Poland's second largest city.
Police said the attacker drove on to Main Market Square in Krakow, a popular tourist attraction, on Saturday afternoon and fired randomly at people.
Four women and two men were killed. Three were Polish, one was British and two have not been identified.
Among the 16 injured are five foreign nationals from Austria, Germany, Portugal, Russia and Britain.
Another three bodies were found when counter-terrorism police searched the suspect's home around 125 miles (200km) away, Polish Prime Minister Donald Tusk said.
A massive armed police presence was deployed across Krakow on Saturday evening, as security measures were ramped up in the capital Warsaw and elsewhere.
A period of mourning has been declared in Krakow until 11 November.
Two police officers are also among those injured, one critically.
The suspect, who was equipped with military-style weapons and attire, is a 25-year-old Polish man - described by a minister as "ultra-nationalist".
Police shot and arrested him and he remains in hospital having undergone surgery.
Tusk said there were "strong indications" the two women and one man found dead at the suspect's home in Ostrowiec Świętokrzyski were his immediate family members.
He said: "Until now in Poland we haven't had such drastic cases of terrorism... that's what we have to call this cruel attack on people's lives here in Krakow."
UK Prime Minister Andy Burnham said: "I'm shocked and saddened by the appalling shooting in Kraków today."
"My thoughts are with the families of those who have lost their lives, everyone injured and all those affected by this senseless violence. The United Kingdom stands in solidarity with the people of Poland," he added.
The rampage began shortly before 15:00 local time (14:00 GMT) in the historic centre of Krakow, an ornate square which has long been a draw for tourists.
Footage showed the attacker's vehicle speeding through the centre of the city, and people fleeing as the sound of gunfire rang out.
The glass front of shops were shattered by bullets and a tram was shot at during the attack, which police say lasted for around three minutes.
Images from the scene show overturned tables and scattered belongings left behind as people ran for their lives.
Armed police officers pursued the attacker's car until it crashed, at which point they engaged him in a firefight.
Distressing footage authenticated by BBC Verify captured the moment a police officer confronted the suspect as he lay on the ground.
The officer, who is visibly injured, can then be seen falling to the ground.
A Polish minister later said one police officer was fighting for his life and a second was expected to recover from a less serious injury.
Tusk later named them as Senior Constable Jakub Kulik and Senior Constable Artur Morański - he said they had "saved many lives" and called them "true heroes".
The gunman wore full military tactical gear during the attack and was described as having a military-grade weapon - but the government said he was not a member of the Polish armed forces.
More weapons and ammunition were found in a car belonging to the suspect, whose name has not been confirmed.
Poland's Interior Minister Marcin Kierwiński said "everything suggests that he was fascinated by far-right ideologies" and held "ultra-nationalist views".
Tusk vowed that any "possible supporters of the perpetrator" would be detained and appealed to the public for information.

EU foreign policy chief Kaja Kallas called the attack a "tragedy that will be felt far beyond Poland."
British Foreign Secretary Ed Miliband said on social media the UK government "deeply mourns" those who died in the "appalling attack".
"All of my deepest condolences go to the families of the victims," he added.
The Foreign Office updated its advice after the attack and said people in the area should follow the guidance of local authorities.
Witnesses who were close to the attack described panic and confusion around the square as it unfolded.
Cezary, a 24-year-old Polish university student in Krakow, said he had not realised the loud bangs he heard were gunshots until he saw four bodies lying on the street.
"We were still hearing gunshots, a lot of people were screaming," he said, adding that he had seen someone trying to resuscitate a person covered in blood on the ground.
Caitlin Shasby, from Newcastle in the UK, said she had heard shooting from her hotel room and had been told to take shelter inside as police "barricaded" the street outside.
Another witness told Polish news website Interia: "I saw shots being fired from the driver's side window and smoke was coming out.
"I ran to the police station in the main market square - when I burst inside, it was full of people hiding on the floor."