An armoured police vehicle blocks a road leading to a nightclub where a armed attack took place
VON PRESS Middle East: The gunman shot dead a police officer and a civilian at the entrance to the Reina club, one of the city's most exclusive nightspots, and then went on a shooting rampage inside, Turkish officials said.
Interior Minister Suleyman Soylu said the attacker escaped and was now the target of a major manhunt, expressing hope the suspect "would be captured soon".
He added that of 21 victims who have been identified so far, 16 are foreigners and five are Turks. Another 69 people are being treated in hospital.
"The attacker -- in the most brutal way -- targeted innocent people who had only come here to celebrate the New Year," Istanbul governor Vasip Sahin said at the scene on the shores of the Bosphorus.
Dogan news agency said there were two gunmen dressed in Santa Claus outfits, although this has yet to be confirmed.
Sahin said the attack began at 1:15 am Sunday (2215 GMT), just after hundreds of revelers had seen in 2017 at the club in the Ortakoy district on the European side of the city.
Local media reported that some witnesses claimed the assailants were "speaking Arabic" while special force police officers are still searching the club.
"They say 35 to 40 died but it's probably more because when I was walking, people were walking on top of people," professional footballer Sefa Boydas told AFP.
"No terror attack will destroy our unity, or eradicate our fraternity or weaken Turkey's effective fight against terror," Justice Minister Bekir Bozdag wrote on Twitter.
Mainly Muslin Turkey's religious affairs agency Diyanet condemned the attack, saying the fact it took place in a nightclub "was no different to it being in a market or place of worship".
As is customary after such attacks in Turkey, the authorities slapped a broadcast ban on images from the incident.
Interior Minister Suleyman Soylu said a gunman who stormed an Istanbul nightclub killing 39, escaped
Turkey has been hit by a wave of attacks blamed on Kurdish militants and ISIS terrorists and 2016 saw more attacks than any other year in the history of the country.
On December 10, 44 people were killed in a double bombing in Istanbul after a football match hosted by top side Besiktas, an attack claimed by the Kurdistan Freedom Falcons (TAK) seen as a radical offshoot of the outlawed PKK rebel group.
In June, 47 people were killed in a triple suicide bombing and gun attack at Istanbul's Ataturk airport, with authorities blaming ISIS.
And in one of the latest strikes, an off-duty police officer assassinated Russia's ambassador to Turkey in an Ankara art gallery less than two weeks ago.
Turkey is still reeling from a failed July coup blamed by the government on the US-based Islamic preacher Fethullah Gulen that has been followed by a relentless purge of his alleged supporters from state institutions.
The US embassy warned citizens that extremist groups are continuing "aggressive efforts to conduct attacks in areas where US citizens and expatriates reside or frequent."
The shooting spree came as the Turkish army wages a four-month incursion in Syria to oust ISIS terrorists and Kurdish militants from the border area, suffering increasing casualties.
From Sydney to Paris, Rio to London, security had been boosted over fears that the New Year festivities could present a target for violent extremists.
In Istanbul, at least 17,000 police officers were deployed and some, as is customary in Turkey, dressed themselves as Santa Claus as cover, according to television reports.