Garlic turns green due to a chemical reaction between the sulfur compounds in garlic and enzymes that are released when the garlic is cut or crushed. The reaction is accelerated by heat, so garlic is more likely to turn green if it is cooked at high temperatures.
The green color is caused by the formation of a compound called allicin. Allicin is a sulfur-containing compound that has a strong, pungent odor. It is also responsible for the health benefits of garlic, such as its ability to boost the immune system and fight against bacteria and viruses.
While green garlic is safe to eat, some people find the color to be off-putting. If you want to prevent your garlic from turning green, you can try the following tips:
* Avoid cutting or crushing garlic until you are ready to use it.
* Cook garlic at lower temperatures.
* Add a small amount of acid to the cooking liquid, such as lemon juice or vinegar.
* Store garlic in a cool, dark place.
Even if your garlic does turn green, it is still safe to eat. The green color is simply a result of a chemical reaction, and it does not affect the taste or nutritional value of the garlic.