The authorities said it was one of three car bombs that were meant to be blown up in crowded areas of the capital on Sunday, the first day back to work from the Eid al-Fitr holiday.
Security forces pursued and destroyed the other two.
Officials said the bombers had been prevented from reaching their intended targets, otherwise the casualty toll would have been higher.
There was no immediate claim of responsibility for the attack. Damascus was hit by two separate, multiple suicide bomb attacks in March, one of them claimed by Islamic State and the other by the Islamist insurgent alliance Tahrir al-Sham.
A Syrian boy stands next to the cordoned off area at the site of a suicide bomb attack in the capital Damascus’ eastern Tahrir Square district, July 2, 2017. AFP
In a letter to the UN secretary general and the head of the security council, the foreign ministry said the blast that killed 20 people in the Bab Touma area near the Old City had also wounded dozens of women and children.
State media said the bomber had been spotted and pursued by the security forces and set off the bomb after he had been encircled in the area.
Damascus has enjoyed relative security in recent years even as the six-year-long civil war has raged on in nearby areas.
Footage broadcast by state TV from the blast that caused the fatalities near the Old City showed roads scattered with debris, several badly damaged cars, and another one that had been turned into a pile of twisted metal.
Footage from another of the blast sites showed what appeared to be the remains of a person and badly damaged vehicles outside a mosque in the Baytara traffic circle near the Old City.
On March 15, two suicide bomb attacks in Damascus killed several dozen people, most of them at the Palace of Justice courthouse near the Old City. Islamic State claimed responsibility for that attack.
On March 11, a double suicide attack in the capital killed scores of people, most of them Iraqi Shi’ite pilgrims. That attack was claimed by the Tahrir al-Sham alliance of Islamist insurgents, which is spearheaded by a jihadist group formerly known as the Nusra Front.
Syrian government forces, which have defeated rebel fighters in several suburbs of Damascus over the last year, are currently battling insurgents in the Jobar and Ain Tarma areas on the capital’s eastern outskirts.
A rebel group accused the army of using chlorine gas in the fighting on Saturday. The army denied the claim as fabrications.