An Uzbek gunman who killed 39 people in Istanbul's Reina nightclub on New Year's Day told police he had changed his target at the last minute to avoid heavy security and acted on direct orders from Islamic State in Syria, a newspaper said on Wednesday.

The gunman, named on Tuesday as Abdulgadir Masharipov, had initially been told to attack the area around the central Taksim square and said his instructions came from Raqqa, Islamic State's stronghold in Syria, the newspaper Hurriyet cited him as saying in police testimony.

"I came to Taksim on New Year's Eve but the security measures were intense. It wasn't possible to carry out the attack," he was quoted as saying.