Never rich in the first place, Nicaragua is striving to overcome the after effects of dictatorship, civil war and natural calamities, which have made it one of the poorest countries in the Western Hemisphere.
Nicaragua has traditionally relied on agricultural exports to sustain its economy. But these benefited mainly a few elite families of Spanish descent, primarily the Somoza family, which ruled the country with US backing between 1937 and the Sandinista revolution in 1979.
The Sandinistas began redistributing property and made huge progress in the spheres of health and education. They won a decisive victory in 1984 elections, but their leftist orientation also attracted US hostility and drove them to turn to the USSR and Cuba.
Politics: Former Marxist guerrilla leader Daniel Ortega made a comeback in the November 2006 presidential race
Economy: Nicaragua is the second poorest nation in the Americas, after Haiti; former President Bolaños pursued market-friendly policies
International: The US has been vocal in its opposition to Ortega, who is seen as one of the main players in an increasingly assertive anti-US bloc in Latin America
This set the scene for a US-sponsored counter-revolution, which saw Washington arm and finance thousands of rebels, or Contras, in order to carry out attacks on Nicaragua from bases in Honduras. The US also imposed trade sanctions and mined Nicaraguan harbours.
By 1990, when the Sandinistas were defeated in elections held as part of a peace agreement, Nicaragua's per capita income had plummeted and its infrastructure was in tatters.
Peace brought some economic growth, lower inflation and lower unemployment. But this was more than counter-balanced by the devastations of Hurricane Mitch in 1998, which killed thousands, rendered 20% of the population homeless and caused billions of dollars worth of damage.
Nicaragua's modest tourist industry - which had all but collapsed by the early 1990s - has enjoyed a revival. The country's attractions include wildlife-rich rainforests, volcanos, beaches and colonial-era architecture.
- Full name: Republic of Nicaragua
- Population: 5.8 million (UN, 2011)
- Capital: Managua
- Area: 120,254 sq km (46,430 sq miles)
- Major languages: Spanish, English, indigenous languages
- Major religion: Christianity
- Life expectancy: 71 years (men), 77 years (women) (UN)
- Monetary unit: 1 gold cordoba = 100 centavos
- Main exports: Coffee, meat, shellfish, sugar, tobacco, cattle, gold
- GNI per capita: US $1,170 (World Bank, 2011)
- Internet domain: .ni
- International dialling code: +505
President: Daniel Ortega
Left-wing Sandinista leader Daniel Ortega made his political comeback in the November 2006 elections, having led Nicaragua through revolution and a civil war before being voted out in 1990.
Daniel Ortega is set to run for office again in 2011
Mr Ortega was re-elected to another five-year term with a landslide victory in 2011, winning 63% of the vote. Election observers, opposition figures and US officials voiced concern about the validity of the vote.
His first period in office, between 1985-90, was characterised by a controversial programme of wealth distribution, which triggered hostility from the US administration of Ronald Reagan and armed attacks by US-backed Contra rebels.
By the time he came to stand for re-election in 2006, Mr Ortega had toned down his former fiery rhetoric in an effort to calm fears about his Marxist past.
However, the global financial crisis that began a few years later prompted him to declare that capitalism was in its "death throes".
Mr Ortega has maintained close ties with fellow socialist leaders in the region, in particular with Venezuela's Hugo Chavez.
On the other hand, relations with the right-leaning Colombian leadership - a staunch ally of the United States - have been strained at times.
Although Mr Ortega still enjoys solid support among the poorer parts of Nicaraguan society, his critics have accused him of exhibiting dictatorial tendencies.
In October 2009 the country's Supreme Court amended the constitution to allow him to stand for re-election.
Born in 1945, the young Mr Ortega joined the Sandinista movement in 1963. He rose rapidly through its ranks and was a leading player in the guerrilla war against dictator Anastasio Somoza. He was imprisoned several times.
For most Nicaraguans radio and TV are the main sources of news. There are more than 100 radio stations, many of them in the capital, and several TV networks. Cable TV is available in most urban areas.
The print media are varied and partisan, representing pro- and anti-government positions. Reporters Without Borders has noted "serious tensions" between Mr Ortega's government and the owners of the private media.
There were 600,000 internet users by the end of 2009, around 10% of the population (Internetworldstats.com).