The Old City of Baku with the Flame Towers skyscrapers in the background. File picture: Pavel Golovkin/AP

Moscow - A fire that ripped through a drug clinic in the Azerbaijani capital Baku on Friday has left two dozen people dead, Russian state news agency TASS reported, citing officials in the former Soviet republic.

"The bodies of 24 victims were found on the site of the accident," a joint report from Azerbaijan's Emergencies Ministry, Interior Ministry and Prosecutor General's Office said.

Three of the 34 people rescued from the blaze were hospitalized. A criminal case has been opened by the prosecution authorities, and an investigation team has been established, the joint report said.

The fire completely destroyed a wooden building, in which bed-ridden patients found themselves unable to escape, local media reported.

The blaze has since been extinguished, according to civil defence authorities in the former Soviet republic.