Police identified the suspect as Abdulgadir Masharipov. He along with four others was taken into custody at a residential apartment on Monday.
Police are questioning Abdulgadir Masharipov, an Uzbek national who is accused of shooting dead 39 people on New Year's Day at the Reina nightclub in Istanbul.
Turkish security forces detained Masharipov late Monday night along with four others. Authorities said he was trained in Afghanistan and had clearly acted on behalf of Daesh.
The suspect was nabbed in an apartment in Istanbul's Esenyurt district with his four-year-old son, another alleged member of Daesh and three women from Egypt, Somalia and Senegal.
Police also found two pistols, mobile phone SIM cards, and $197,000 in cash at the apartment. Currencies of various countries were also recovered from the apartment.
Istanbul Governor Vasip Sahin said the suspect had been in Afghanistan and was a "well-trained terrorist," who entered Turkey illegally in January 2016.
Authorities said Masharipov appeared to have repeatedly changed addresses before and after the nightclub attack. He is being questioned at Istanbul police headquarters.
TRT World's Soraya Lennie has this report from the apartment where Masharipov was captured.
Turkey's war on terror
About 50 people have been detained in raids on 152 addresses since the shooting in Turkey's biggest city and commercial hub early on New Year's day.
"Nobody in this country can get away with their crimes. Anyone who committed a crime will be held accountable within the rule of law. The arrest of the perpetrator of the Ortakoy massacre is another example of that. I would like to congratulate our security forces and those others who has participated in this very successful operation," Turkey's President Recep Tayyip Erdogan said after Masharipov's arrest.
Turkish Deputy Prime Minister Numan Kurtulmus said, "Our war with terror and the powers behind it will continue to the end."
"It appears the Reina attack is not just a terrorist organisation's act, but there was also an intelligence organisation involved. It was an extremely planned and organised act," Kurtulmus also said.
TRT World's Francis Collings has more on the operation leading to Masharipov's arrest.