Coffee is a tropical plant which grows between the latitudes of 25 degrees North and 25 degrees South but requires very specific environmental conditions for commercial cultivation. Temperature, rainfall, sunlight, wind and soils are all important, but requirements vary according to the specific varieties grown.
Ideal average temperatures range between 15 to 24ºC for Arabica coffee and 24 to 30ºC for Robusta, which can flourish in hotter, drier conditions but does not tolerate temperatures much below 15ºC, as Arabica can for short periods. All coffee is easily damaged by frost, a danger either in southern Brazil or, closer to the Equator, at altitudes around 2000 metres.
In general, coffee needs an annual rainfall of between 1500 and 3000 mm, with Arabica needing less than other species. The pattern of rainy and dry periods is important for growth, budding and flowering. Rainfall requirements depend on the retention properties of the soil, atmospheric humidity and cloud cover, as well as cultivation practices.
Whereas Robusta coffee can be grown between sea-level and about 800 metres, Arabica does best at higher altitudes and is often grown in hilly areas. As altitude relates to temperature, Arabica can be grown at lower levels further from the Equator, until limited by frost. All coffee needs good drainage, but it can grow on soils of different depths, pH and mineral content, given suitable applications of fertilizer.
Wind-breaks are sometimes planted to protect coffee plantations; shade trees, which may be economic crops such as bananas, are a common feature and mimic the natural habitat of coffee.