Reflecting on the practices of the Prophet, peace and blessings be upon him, as stated in the Prophetic Biography, we will notice fine examples set by the Prophet, peace and blessings be upon him, making it clear that forming some sort of cooperation with non-Muslims in worldly affairs is permissible as long as that will bring benefits to Muslims, and will help establish justice or ward off injustice. Hence, there is nothing in Muslims’ participating in elections run in non-Muslim countries, especially when such participation accrues benefits to Muslims or ward off harms.
The European Council for Fatwa and Research issues the following Fatwa:

Before delving into the matter, we will shed light on the following three aspects:
1-Al-Walaa’ (loyalty).
2-The Prophet’s participation in some activities in Makkan and Medinan societies.
3-The Constitution of Madinah.
-The first aspect:Al-Walaa can be divided into the two sections:
1- Loyalty in religious matters. It refers to creedal loyalty, which lies in believing in Allah and shunning other beliefs that run counter to the Oneness of Allah. This kind of Al-Walaa is due to Allah, His Messenger and the believers. Almighty Allah Says: [Your friend can be only Allah; and His messenger and those who believe, who establish worship and pay the poor due, and bow down (in prayer)] (Al-Ma’dah 5: 55)
2-Loyalty as regards worldly matters: This refers to transactions between people living in the same society or between different societies, regardless the distance and the religion. It is permissible for Muslims to engage with non-Muslims in commercial transactions, peace treaties and covenants according to the rules and conditions prevalent in those countries. Books of Jurisprudence do contain many references about such kind of dealings.
The second aspect: The Prophet’s participation in activities in the Makkan and Madinan societies.
throughout his life before and after the Prophetic mission, Prophet Muhammad, peace and blessings be upon him, participated in many events that took place in the Makkan and Madinan societies. Following are the most prominent events he participated in before being a Prophet.
-First: The Fujjar War:
this war was waged against some Arab tribes who violated the sacredness of the holy sanctuary in the sacred months. Hence, the Makkan people had to defend the holy sanctuary; this was a good custom they inherited from the upright religion of Prophet Abraham. This fight lasted for four years, and the Prophet’s age at that time was around 15-19 years. He participated in this war side by side with his uncles. That is, he would defend his uncles against the enemies’ attack. The Prophet, peace and blessings be upon him, did so out of his sense that he should share in defending his homeland and ward off aggression and injustice.
– Second: Al-Fudul Alliance:
this incident occurred in the house of Abdullah bin Jad`an between the greatest tribes in Makkah. One of the principles they agreed upon was backing up any oppressed person in Makkah, regardless of his origin and the purpose behind his visit; they vowed to help him regain his rights. At the advent of his mission, the Prophet, peace and blessings be upon him, is reported to have said (i.e. while referring to this alliance): “If I am invited to join a similar (alliance) after the spread of Islam, I will, surely, join it.”
Commenting on the aforementioned point regarding the Prophet’s participation in that alliance, Sheikh Muhammad Al-Ghazali stated: “Combatting an oppressor however brutal he may be, and supporting an oppressed however low he may be, are consistent with the spirit of Islam that enjoins what is right, forbids what is wrong and calls for abiding by the limits set by Allah.
Moreover, Islam aims at putting an end to injustice whether in the general policies adopted by countries or oppression at the individual level. The Prophet’s participation in Al-Fudul Alliance reveals the positive attitude he took, for he considered himself part and parcel of the Makkan society. Besides, the Prophet, peace and blessings be upon him, was aware of the fact that if oppression or any form of injustice in the society is not eliminated, their ill effects will befall all and sundry.
third: The Prophet’s Response to SOS Calls:
the humanitarian gestures of the Prophet, peace and blessings be upon him, towards the people of Makkah was not confined to the period he spent with them. This noble attitude continued even after emigrating Makkah to Madinah and establishing the Islamic state there, as he rushed to lend the hand of support when calamities befell the people of Makkah.
It is reported that during the time of Al-Hudaibiyah peace treaty, the Prophet was informed that a famine had afflicted the Makkan people. Thus he sent Hatib bin A
Balta’a with 500 dinars to buy foods for the poor and the needy among the Makkans. You see, he did this despite that it was the same people that drove him out of the city and even hindered him from entering it.
-The third aspect: The constitution of Madinah:
Considering the constitution of Madinah or the treaty held between Muslims, Jews and the Arab polytheists who constituted the population of Madinah at that time, after emigration, one will notice that the Prophet, peace and blessings be upon him, stressed the importance of showing belonging and patriotism to the society. Thus, he made it clear that this is a general duty shared by all regardless of religions, races or complexions. The treaty stipulated the following:
1-They (those who sign the treaty) should support one another in combating the attacks waged against any of them.
2-They, together, should back up the oppressed.
3-They, together, should fight against any enemy attacking Yathrib (Madinah).
We deduce from these three aspects that the early Muslims managed to cooperate with people of other religions, living together in the same society of Madinah, in fighting against anyone who tried to bring about sedition among people. Thus, they maintained peaceful co-existence within the same society.
this form of Al-Walaa comes under what we ter
m ‘Al-Walaa in worldly affairs’. It states that citizens can live together in the same society in spite of their different faiths and religious orientations. Moreover, the Constitution of Madinah regarded the People of the Book as part and parcel of the first Islamic State. For instance, some of its articles state:
1- The Jews of the tribe of BanuAwf are part of the Muslim community.
2- Jews have their own religion and Muslims have their own religion.
3- The rest of the Jewish tribes have the same rights as do the tribe of Banu ‘Auf.
Considering the issue of Al-Walaa, it is evident that there’s nothing wrong Islamically in having some sort of such cooperation between Muslims and non-Muslim as regards worldly affairs. Besides, the Prophetic Biography is abound with fine examples of how the Prophet, peace and blessings be upon him, dealt amicably with non-Muslims, both in the Makkan and Madinan societies. He shared in many pacts and alliances aiming at eliminating injustice and aggression, in addition, he shared in relieving the impact of adversities and famines.
according to the articles of the Madinah constitution, the residents of Madinah would cooperate in establishing justice, supporting one another in combating aggression and help one another do righteous acts.

So it’s clear that mutual cooperation in worldly affairs goes far to encompass all citizens who share a common destiny, neighborhood and sometimes kinship. This may be extended to include economic and commercial fields. In addition, the teachings of Islam, as deduced from the Qur’an and Sunnah, show that Islam is a religion of mercy, justice, goodness. One of the main goals of Islamic law is to achieve benefits and ward off harms, whether at the level of individuals or at the level of society.
Furthermore, elections in the modern world systems have become a means through which peoples choose candidates and judge the programs they adopt. Muslims living in such societies enjoy rights and are bound to do some duties. If they fail to meet the duties obligated on them, they are no more entitled to receive the rights, for the rights meet the duties.
thus, Muslims’ participation in elections is a national duty; in addition it falls under cooperation on that which is good and righteous for the society and wording off harms from it, Allah Almighty says: [… help ye one another unto righteousness and pious duty. Help not one another unto sin and transgression…] (Al-Ma’dah 5: 2)
Therefore, we can say that Muslim’s participating in elections held in non-Muslim societies is Islamically permissible and there is nothing wrong in doing so. Besides, it is a kind of mutual cooperation with those whom Muslims think as potential candidates who, if they win the elections, will bring benefits for the society in general and Muslims in particular.