Why does my beer taste like apples?
If you've just cracked open a homebrew and find that it has a green apple flavor you've probably have acetaldehyde. Unless, of course, you added apples or apple juice to your beer. But then you probably wouldn't be here wondering where that strange flavor came from. Other flavor descriptions of acetaldehyde include freshly cut pumpkin, cut grass, and green leaves, personally it reminds me of green Jolly Ranchers. In large quantities it really jumps out at you and makes you say, "what's wrong with this thing. I swear I didn't make a cider."
Where does it come from?
Acetaldehyde is commonly a sign of a young beer that didn't have enough time to fully condition in the fermentor. Young beers are often called “green” beers which nicely lines up with that green apple flavor they produce. During the fermentation process yeast create acetaldehyde as it converts sugars into alcohol. Luckily for us the yeast will remove the acetaldehyde given enough time.
It is also possible to create acetaldehyde from oxidation of a finished beer. When ethanol is exposed to oxygen the enzyme ethanol dehydrogenase will convert the ethanol into acetaldehyde.
And, lastly, some yeast strains and bacteria are particularly inclined to produce acetaldehyde.
How to stop it?
The best thing you can do is let your beer sit and fully condition and not rush through fermentation. You can test your beer while it's still in the carboy. If you don't have a thief you should pick one up. If you taste some green apple let the beer rest another couple days. Also, avoid introducing oxygen to your finished beer and not just because of acetaldehyde--oxygen can do all sorts of bad things to your beer. And, as always, keep your gear and environment clean and sanitized to avoid picking up any unwanted bacteria.
Can I do anything once it's in my beer?
As long as you catch it when the beer is still conditioning with the yeast. If you pick this up in the bottle? Then no. You're out of luck. I hope you like green apples.
Some beers like this stuff
Not all beers hate acetaldehyde. Some beers are known for having this character at small levels. One big one is Budweiser. It is also one of the reasons I am not a fan of Budweiser. I find the flavor totally off-putting. A more pleasant example would be Paulaner’s Salvator where it adds complexity to an already rich beer. In general, acetaldehyde is considered a flaw and would be treated as such in a competition.
Threshold: 10ppm or 100-125 mg/L
Chemical makeup: CH3 CHO
Acetaldehyde is a very interesting chemical compound. While I was researching this post I went down the Wikipedia rabbit hole and learned a few things that don't have much to do with brewing beer but are nonetheless interesting. I am not a chemist and don't know enough comment on anything beyond brewing beer, but the most interesting takeaway is that Acetaldehyde is one of the main components in causing hangovers. Interesting. Right? It's a paticualrly toxic compond (30 to 40 times more toxic than alcohol according to Wikipedia) and plays a significant role in the Alcohol Flush Reaction. Acetaldehyde is also used as a precursor to creating acetic acid. Tobacco smoke has acetaldehyde and according to Wikipedia is the most abundant carcinogen in Tobacco smoke. Not the most pleasant sounding thing when you see all that this chemical is up to.
The following was used in the writing of this post: Brewing Better Beeer by Gordon Stong, Tasting Beer by Randy Mosher, BJCP Study Guide, Wikipedia entries on Acetaldehyde, Hangovers, and Wine Faults.