The War of the Pacific sprung from competing claims over a mineral-rich portion of the Atacama Desert, over which Bolivia, Chile, and Peru all claimed control.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivians hold national flags as they watch the reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

The three countries had claimed the area since they gained their independence from Spain in the 1820s, and a tax dispute prompted the war in 1879.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers rest before a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

The Battle of Canchas Blancas took place in western Bolivia on November 12, 1879. According to the recently discovered diary of a Bolivian colonel, several hundred Bolivian soldiers, peasants, and indigenous people armed with machetes, clubs, and stones defeated a force of about 1,500 Chilean soldiers backed by cavalry and artillery.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers rest before a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Latin American Herald Tribune

The defeat halted the Chilean force's advance toward Paraguay. More than 300 were killed, but the victory is a source of pride for Bolivia. Chilean historians have disputed whether the battle even happened, though, with one saying, "the battle is sort of a legend generated in the bosom of the Bolivian army."

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers take part in a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Latin America Herald Tribune, La Tercera, El Mercurio Nacional

"Our Indians and soldiers saved the fatherland," Morales said at the reenactment, lamenting the "Chilean oligarchy" that he said was holding on to a "colonial mentality" about the war and its resolution.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers take part in a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Latin American Herald Tribune

Soon after its defeat at Canchas Blancas, however, Chile gained the advantage, occupying Lima, the Peruvian capital, in 1881. By 1883, Peru had left the conflict, signing a peace deal.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers take part in a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

Bolivia signed a peace treaty with Chile in 1884. Its quest to regain access to the sea would lead it into another conflict a half-century later: the brutal Chaco War, in which Paraguay rebuffed Bolivia's efforts to reach the Atlantic via the Rio de la Plata river system.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Officers riding horses take part in a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider, Encyclopedia Britannica

From the conflict, Chile gained what are now its three northernmost regions, whose resources supplied Chile most of its government revenues for the next 40 years.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivian soldiers take part in a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

Bolivia lost more than 46,000 square miles of territory, including the copper-rich Antofagasta region. Peru lost vital resource-rich provinces in its south, though it gained some territory back in 1929.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
A reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

Bolivia, which maintains a navy, has not relented in efforts to regain access to the sea, a campaign that has strained its relations with Chile. The two countries have not had full diplomatic relations in decades.

Chile Bolivia war of the pacific Canchas Blancas battle reenactment
Bolivia's President Evo Morales, second left, receives a painting from army Cmdr. Gen. Willam Kaliman Romero during a reenactment of the battle of Canchas Blancas, March 28, 2018.
REUTERS/David Mercado

Source: Business Insider

Bolivia filed suit with the International Court of Justice in 2013, asking it to compel Chile to negotiate "in good faith." "Bolivia is not asking to be granted a wish," Morales said on Twitter this month. "Bolivia demands that its sovereign right to the sea be returned."

Evo Morales Bolivia army Canchas Blancas battle reenactment
Bolivian President Evo Morales presides over the reenactment of the Battle of Canchas Blancas, a Bolivian victory in the War of the Pacific, March 28, 2018.
Evo Morales/Twitter

Source: Business Insider, Evo Morales