Sheikh Ahmad Kutty, a senior lecturer and Islamic scholar at the Islamic Institute of Toronto, Ontario, Canada, states: “As far as vanilla extract is concerned, if it contains alcohol, it is considered unlawful for us to consume; in fact, that is the case when it is “extracted with alcohol as the solvent of choice, from the vanilla bean” and “kept in a solution containing alcohol.” Usually alcohol is listed as an ingredient on the bottle of vanilla extract; if it has been listed, it is quite clearly forbidden for us to consume.
However, vanilla, we are told, “can also be used in the powdered form. In this form, the beans are either crushed without the addition of alcohol, or they are crushed, dissolved in alcohol and then purified. During purification, the alcohol is distilled off so there is no alcohol remaining.” In this case, there is nothing wrong in using this.
In conclusion: while deciding to use vanilla we must exercise caution and make sure that it is free of alcohol. So read the labels on the bottles or containers carefully, and in case of doubt, check with the company that produces it.
Moreover, the prominent Muslim scholar, Sheikh Muhammad Iqbal Nadvi, Director and Imam of Al-Falah Islamic Center, Oakville, Ontario, Canada, adds:
“The Shari’ah rule states: “What intoxicates in big amounts, a small amount of it is also haram.” So, if anything contains alcohol as ingredient, it will be considered haram. The only exception occurs when it is a case of darurah or necessity. For example, if someone is in need of medication, and the only medication available in the market contains alcohol, then it will be considered halal for him, not for others.”
As for cakes icing which are made with alcohol, we’d like to make it clear that it is not allowed for Muslims to use wine in any form or shape. So, it is not permissible to consume such cakes.