Oil-rich Azerbaijan gained independence from the Soviet Union in 1991 amid political turmoil and against a backdrop of violence in Nagorno-Karabakh.
It has been famed for its oil springs and natural gas sources since ancient times, when Zoroastrians, for whom fire is an important symbol, erected temples around burning gas vents in the ground.
In the 19th century this part of the Russian empire experienced an unprecedented oil boom which attracted international investment. By the beginning of the 20th century Azerbaijan was supplying almost half of the world's oil.
In 1994 Azerbaijan signed an oil contract worth $7.4bn with a Western consortium. Since then Western companies have invested millions in the development of the country's oil and gas reserves. However, the economy as a whole has not benefited as much as it might have done.
At a glance
- Politics: President Ilham Aliyev came to power in 2003, succeeding his father Heydar, and was re-elected in 2008 and in 2013. A two-term presidential limit was abolished in 2009. Critics accuse Mr Aliyev of heading an authoritarian regime which suppresses opposition
- Economy: Huge oil export revenues have funded infrastructure projects and boosted living standards
- International: Azerbaijan and Armenia fought in the 1990s over disputed Nagorno-Karabakh; a fragile ceasefire is in place. Relations with Iran and Russia are fractious
Country profiles compiled by BBC Monitoring
Caspian oil is now flowing through a pipeline running from Baku through Georgia to the Turkish port of Ceyhan, providing western countries with ready access to a vast new source of supply. Environmental groups have protested that the cost of this benefit is unacceptable.
Azerbaijan has large gas reserves, and in September 2014 BP began construction of the Southern Gas Corridor to supply Europe directly by 2019, bypassing Russia.
Azerbaijan became a member of the Council of Europe in 2001. Often accused of rampant corruption and election-rigging, ruling circles walk a tightrope between Russian and Western regional geo-strategic interests.
As the Soviet Union collapsed, the predominantly Armenian population of the Nagorno-Karabakh region stated their intention to secede from Azerbaijan. War broke out. Backed by troops and resources from Armenia proper, the Armenians of Karabakh took control of the region and surrounding territory.
In 1994 a ceasefire was signed. About one-seventh of Azerbaijan's territory remains occupied, while 800,000 refugees and internally displaced persons are scattered around the country.