As civil war raged throughout Central America, mainly due to those in the effort to reassemble it in the form of non democratic rule under filibuster William Walker, Costa Rica became a safe have and shined with promise of civil rest and sanity.
William Walker was an American filibuster who usurped the power in Nicaragua and was spreading in an attempt to control the Central American region being defeated by Central American forces. He was driven from Costa Rica in the Battle of Santa Rosa where he was ambushed and the battle lasted 15 minutes, sending his invading forces back into Nicaragua. Later he was captured and sentenced to death by the Guatemalan government. I firing squad was his death. He is now buried in Trujillo, Honduras.
This area was considered the new land of opportunity, with the California gold rush and a French promoted plan to create a canal on Nicaragua-Costa Rican border. This would ensure that Guanacaste would then become a world trade center. The United States invested in the Panama railroad, but the passage was expensive forcing many Europeans to travel the dangerous routes across the US or a long ride down and around Cape Horn. The Transcontinental was not yet completed. So many would save money by traveling across the ocean then changing to smaller ships to travel up the San Juan river to change onto steamboat across Lake Nicaragua and finally on pack mules to San Juan del Sur.
Interests to build the Nicaragua Canal still exist, although US interest dropped once France sold them the rights to build the Panama Canal. Nicaraguan president has negotiated with a Chinese businessman for concession and construction, but due to a Chinese market crash, this has not been possible while Panama Canal expands and Costa Rica improves a container port in Limon.