The suspect was captured in a special operations police raid on a house in Istanbul's Esenyurt district, private NTV television reported. The broadcaster said he had been staying in the house belonging to a friend from Kyrgyzstan.
The Islamic State group has claimed responsibility for the nightclub massacre, saying the attack in the first hours of January 1 was in reprisal for Turkish military operations in northern Syria. The man identified as the suspect had been on the run since the attack.
Hurriyet newspaper and other media have identified the gunman as Abdulkadir Masharipov, an Uzbekistan national. The suspect was to undergo medical checks before being taken to police headquarters for questioning, the paper said in its online edition.
Dogan news agency published what it said was the first image of the attacker. It showed a bruised, black-haired man in a grey, bloodied T-shirt being held by his neck. Private NTV television said the gunman had resisted arrest.
NTV reported that the gunman's Kyrgyz friend and three other people also were detained. His 4-year-old child, who was with him at the home, was taken into protective custody.
The television channel said police established the gunman's whereabouts four or five days ago, but delayed the raid so they could monitor his movements and contacts.
The state-run Anadolu Agency also reported the arrest and identified the gunman, only with a slightly different spelling of his first name, Abdulgadir. It said a Kyrgyz man and three women were detained with him
Anadolu said the suspects were being taken to Istanbul's main police headquarters for questioning. Police were carrying out raids on other suspected Islamic State group cells, the news agency said without providing details
Earlier in the day, Turkish Deputy Prime Minister Numan Kurtulmus said the Reina nightclub attack had been carried out professionally with the help of an intelligence organization, a claim he had made in the first days after the attack. He did not name the organization suspected of being involved.
Hundreds of people were gathered at the swanky Reina nightclub to celebrate the end of a tumultuous 2016 only to become the first victims of 2017. The gunman shot a police officer and a civilian outside the club, then stormed the premises.