Armed police sealed off streets around the Vodafone Arena Stadium, home to the Beşiktaş football team, a Reuters witness said. TV footage showed what appeared to be the wreckage of a burned out car and two separate fires on the road outside the stadium.
President Tayyip Erdogan described the blasts as a terrorist attack on police and civilians. He said the aim of the bombings, two hours after the end of a match attended by thousands of people, had been to cause the maximum number of casualties.
"Nobody should doubt that with God's will, we as a country and a nation will overcome terror, terrorist organizations ... and the forces behind them," he said in a statement.
Interior Minister Suleyman Soylu said the first explosion, which came around two hours after the end of the match between Beşiktaş and Bursaspor, was at an assembly point for riot police officers. The second came as police surrounded the suicide bomber in the nearby Macka Park.
Seven of those killed in the blasts were civilians, while another 30 were police officers, including a police chief and another senior officer, Soylu said. He said 17 of the wounded were undergoing surgery and another six were in intensive care.
Soylu also said 10 people had been detained based on evidence from the detonated vehicle, but gave no indication of who the authorities thought might be behind the attack.
Broadcaster NTV said the explosion targeted a police vehicle that was leaving the stadium after fans had already dispersed.
Bursaspor said none of its fans appeared to have been injured.
"We have contacted our fan groups. There appear to be no injuries among our fans. We wish injured citizens a quick recovery," Bursaspor said in a statement on its Twitter account.
Turkey has been hit by a series of bombings in recent years, some blamed on ISIS militants, others claimed by Kurdish and far-leftist militant groups.
Istanbul has seen several other attacks this year, including in June, when around 45 people were killed and hundreds wounded as three suspected ISIS militants carried out a gun and bomb attack on its main Ataturk airport.