A series of explosions has rocked the Indonesian capital, Jakarta, with gun battles on the streets.
The blasts were centred around Thamrin Street, a major shopping and business district close to foreign embassies and the United Nations offices.
Police say the situation is now under control, with five suspected attackers among at least seven people killed.
So-called Islamic State (IS) said it carried out the attacks, a news agency linked to the militant group said.
Separately, Indonesian police said they suspected a local group allied to IS was to blame.
Indonesian President Joko Widodo described the attacks as an "act of terror".
"We all are grieving for the fallen victims of this incident, but we also condemn the act that has disturbed the security and peace and spread terror among our people," he said.
Images from Jakarta have shown several bodies lying on the road outside a cafe, as well as seriously injured people being carried away.
Details remain unclear, but at least one of the blasts hit a Starbucks cafe and a police security post.
It appears the gunmen then holed up in the Djakarta Theater, part of the complex that houses the Starbucks.
Armed police, snipers and armoured vehicles were deployed on the streets of the capital.
Gunfire broke out after police arrived at the cafe - there were several further explosions and reports of police chasing suspects. Sporadic gunfire was reported for several hours afterwards.
A UN official, Jeremy Douglas, told the BBC he was about 150m (450ft) away from one of the first blasts near the UN's building.
"Then we ran into the building. We heard a third explosion. We got up to our office on the tenth floor and we heard a fourth, a fifth and a sixth."
Islamist attacks in Indonesia
Indonesia has suffered militant attacks in the past, but has been relatively successful in curbing home-grown Islamist extremism after a spate of attacks in the last decade. Some of the deadliest include:
- July 2009: Seven people killed and dozens wounded when two suicide bombers target Marriott and Ritz Carlton hotels in Jakarta
- Oct 2005: Suicide attacks in Bali leave 23 dead, including the bombers
- Sept 2004: Bomb outside Australian embassy in Jakarta kills at least nine people
- Aug 2003: Bomb at Jakarta's Marriott Hotel kills 12
- Oct 2002: Bali bombings kill 202, including 88 Australians
- Dec 2000: Church bombings across the country kill 19
A few hours later, police said four attackers had been killed, then shortly after revised the number to five, including a foreigner.
National Police Deputy Chief Commander Gen Budi Gunawan said two had been killed in a shootout outside a theatre and two others blew themselves up at the police post in front of Starbucks.
Police spokesman Col Muhammad Iqbal said the situation was "under control", with no suspects hiding inside the shopping centre.
Police had initially said there could be up to 14 assailants. Three attackers have been arrested, reports say.
New danger for security services, by BBC Security Correspondent Frank Gardner
Today's attack on the Indonesian capital is sadly part of a pattern that has been repeating itself in several cities around the world in recent months.
Istanbul, Paris and now Jakarta have all experienced what counter-terrorism officials classify as a 'Marauding Terrorist Firearms Attack', or 'MTFA' for short.
In other words, police forces have had to react quickly to the sudden appearance of an unknown number of gunmen rampaging through the heart of an urban area, intent on killing as many people as possible and securing themselves maximum publicity.
The aim for the authorities in each case is to bring the situation under control as fast as possible with minimal loss of life, something that UK and other forces have been rehearsing for ever since the disastrous Mumbai siege of 2008.
But preventing such attacks requires better intelligence and needs more effective sharing of information among the people who need to know it.
Indonesia has been attacked by Islamist militant groups in the past and was on high alert over the new year period after threats from the so-called Islamic State (IS).
There has been no confirmation of the group's claim it carried out the attack, but National police spokesman Anton Charliyan said the group had earlier warned of a "concert in Indonesia" which would be international news.
He said the attackers had tried to imitate the co-ordinated attacks on Paris and there was a "strong suspicion that this is an Isis (Islamic State)-linked group in Indonesia".
Up to 200 Indonesians are estimated to have gone to Syria to fight with IS.
Indonesia is the world's most populous Muslim nation but by and large is secular, although in recent years the threat of radicalism has remained high as small networks of militants are still thought to be operating in the country.
Are you in Jakarta? Have you been affected? If it is safe to do so, let us know about your experiences. Email firstname.lastname@example.org with your stories.
Please include a contact number if you are willing to speak to a BBC journalist. You can also contact us in the following ways: