[1] Keith's work on the Costa Rican railroad to the Caribbean, a project begun by his uncle Henry Meiggs, led him to become involved in the large-scale export of bananas to the United States.
Having saved $3,000 in a year, Keith bought a cattle ranch located on a river island near the mouth of the Rio Grande, in southern Texas, which he administered until 1871.
[2] In 1871, Keith's uncle Henry Meiggs had signed a contract with the government of Costa Rican president Tomás Guardia Gutiérrez for the construction of a railroad from the capital city of San José to what was to become the Caribbean port of Limón.
At the time, Costa Rica's economy was based primarily on the export of coffee, which was grown in the country's central valley and transported by oxcart to the Pacific port of Puntarenas.
The construction of that railroad proved extraordinarily challenging due to inadequate financing, compounded by the rugged terrain, thick jungle, torrential rains, and prevalence of malaria, yellow fever, dysentery, and other tropical diseases.
In exchange, the government of President Próspero Fernández Oreamuno gave Keith 800,000 acres (324,000 hectares) of tax-free land along the railroad, plus a 99-year lease on the operation of the train route.
These terms were made official in a document signed by Keith and cabinet minister Bernardo Soto Alfaro on April 21, 1884 (known to Costa Rican historians as the "Soto-Keith contract").
In 1899, he was forced by a financial setback to combine his venture with Andrew W. Preston's Boston Fruit Company, which dominated the banana trade in the West Indies.
[6] In 1904, Keith signed a contract with the President of Guatemala, Manuel Estrada Cabrera, giving the company tax-exemptions, land grants, and control of all railroads on the Atlantic side of the country.