During roasting, citric acid reaches a maximum at light to medium roasts then quickly diminishes as roasting levels progress. A typical medium roast will lose about 50% of its initial citric acid concentration and with progressive destruction in latter stages of roasting progresses.
From a taste perspective, citric exhibits strong sour characteristics similar to what we would taste in unripe fruits. Although pure citric acid is commonly used as a food additive to impart sour/tart notes, excessive citric acid is a sign of bad processing.
Since a high concentration of citric acid is found in unripe (green) cherries, it is important for producers to only pick the ripest beans, especially for those bean destined to become specialty coffee.
Unripe/Ripe Coffee Cherries
However, as maturation continues citric acid levels continue to decrease with a parallel increase in sugar production. Generally, Kenyan coffee tend to have lower levels of citric acid than those of Central America, suggesting a less advanced form of plant metabolism.