There is no sharia-based text which indicates that wearing a beard of any length is a prerequisite for leading people in prayer.
Sheikh Ahmad Kutty, an Islamic scholar said:
“There is nothing in the sources of jurisprudence that states that wearing a beard of a certain length is a prerequisite for the validity of imamah (leading people in prayer). The criteria for imamah, as stated in a Prophetic hadith, are as follows:
1. The one who is most knowledgeable about the Qur’an should lead the prayer.
2. If the people are all equally proficient in it, then the one who is most knowledgeable about the Sunnah should lead.
3. If they are equally proficient in it too, then the one who made hijrah first (which no longer exists today, and therefore the one who has contributed the most to the cause of Islam).
Having said this, however, we must say that the Prophet (peace and blessings be upon him) has forbidden anyone who is disliked by people to lead them in the prayer.
In conclusion, let us not make the issue of imamah a contentious one; rather we should select someone to lead us who has the essential requirements of knowledge and piety.
In addition, we have to differentiate between the Islamic ruling regarding the growing of the beard and the conditions for leading people in prayer. Though growing a beard is considered a great Sunnah of the Prophet (peace and blessings be on him), however, the scholars differ regarding whether it is obligatory or recommended to grow it.