After the lesser signs of the Hour appear and increase, mankind will have reached a stage of great suffering. Then the awaited Mahdee will appear; he is the first of the greater, and clear, signs of the Hour. There will be no doubt about his existence, but this will only be clear to the knowledgeable people.
The Mahdee will rule until the al-Maseeh ad-Dajjaal appears, who will spread oppression and corruption. The only ones who will know him well and avoid his evil will be those who have great knowledge and Îmān.
Ad-Dajjal will remain for a while, destroying mankind completely, and the earth will witness the greatest Fitnah in its history. Then ‘Eesa (alayhi-salām) will descend, bringing justice from heaven. He will kill ad-Dajjaal, and there will be years of safety and security.
Then the appearance of Ya’jooj and Ma’jooj will take mankind by surprise, and corruption will overtake them again. In answer to ‘Eesa prayer to Allāh ﷻ, they will die, and safety, security, justice, and stability will return. This state of affairs will continue for some years, until the death of ‘Eesa.
The Ulamaa differ concerning the order in which the other greater signs of the Hour will come about. They are:
• The destruction of the Ka’bah and the recovery of its treasure.
• The rising of the sun from the west.
• The emergence of the Beast from the earth.
• The smoke.
• A wind will take the souls of the believers.
• The Qur’ān will be taken up into heaven.
• A fire will drive the people to their last gathering place.
• The Trumpet will be sounded: at the first sound everyone will feel terror; at the second sound all will be struck down; at the last sound all will be resurrected.
والله اعلم 🍃
Taken from Signs Before the Day of Judgement
The Mahdee will come at the end of time; he is one of the Rightly-Guided Caliphs and Imāms. He is not the Mahdee who is expected by the
Shee’ah, who they claim will appear from a tunnel in Saamarraa. This claim of theirs has no basis in reality nor in any reliable source. They allege that his name is Muhammad ibn al-Hasan ibn al-Askaree, and that he went into the tunnel when he was five years old.
The matter we intend to discuss has been proven by Ahaadeeth narrated from the Prophet ﷺ: that the Mahdee will appear at the end of time. I believe that he will appear before ‘Eesa the son of Mary comes down, as the Ahaadeeth indicate.
Hajjaaj said that he heard Alee say, “The Prophet ﷺ said, “Even if there were only one day left for the world, Allāh would send a man from among us to fill the world with justice, just as it had been filled with oppression and justice.” [Ahmad] 
Alee said, “The Prophet ﷺ said, “The Mahdee is one of us, from among the people of my household. In one night Allāh will inspire him and prepare him to carry out his task successfully.” [Ahmad and Ibn Maajah] 
Alee said, whilst looking at his son al-Hasan, This son of mine is a Sayyid (master), as the Prophet ﷺ named him. Among his descendants there will be man named after your Prophet ﷻ. He will resemble him in behaviour but not in looks. Then he told them the report which mentions that the earth will be filled with justice. [Abū Dawūd] 
Abū Dawūd devoted a chapter of his Sunan to the subject of the Mahdee. At the beginning of this chapter he quoted the Hadeeth of Jaabir ibn Samrah, in which the Prophet ﷺ said, “This religion will remain steadfast until twelve caliphs have ruled over you.” (According to another report he said, “This religion will remain strong until twelve caliphs have ruled over you.”) Jaabir said, “The people cheered and shouted Allāhu Akbar! Then the Prophet ﷺ whispered something. I asked my father ‘What did he say?’ My father said, ‘He said, All of them will be from Quraysh.'” Another report says that when the Prophet ﷺ returned to his house, Quraysh came to him and asked, “What will happen after that?” He said, “Then there will be tribulation and killing.” 
Abū Dawūd reported a Hadeeth from Abd Allaah ibn Masood: “The Prophet ﷺ said, “If there were only one day left for the world, that day would be lengthened until a man from among my descendants or from among the people of my household, was sent; his name will be the same as my name, and his fathers name will be the same as my fathers name. He will fill the earth with justice and fairness, just as it will have been filled with injustice and oppression. The world will not end until a man of my household, whose name is the same as mine, holds sway.” 
1 Ahmad, al-Musnad; similar Hadeeth in Abū Dawūd, Kitaab Awwal al-Mahdee.
Checker’s Note: Saheeh, Ahmad and Abū Dawūd, Saheeh al-Jami as-Sagheer: 5305.
2 Ahmad, al-Musnad and Ibn Maajah, Kitaab al-Fitan.
Checker’s Note: Saheeh, Saheeh al-Jami as-Sagheer: 6735. It has been mistranslated slightly, it should be “In one night, Allāh will prepare him,” the mention of inspiration and the carrying out of the task is explanatory.
3 See Abū Dawūd, Kitaab al-Mahdee.
Checker’s Note: Da’eef Munqati’ (chain of narration is broken), al-Mishkat, 1st checking: 5462.
4 Checker’s Note: “… returned to his house” is a da’eef addition. The rest of the hadeeth is saheeh.
5 See Abū Dawūd, Kitaab al-Mahdee.
Checker’s Note: Saheeh, Saheeh Abū Dawūd: 3601.
Abd Allaah said, “The Prophet ﷺ said, ‘A man from my household, whose name is like mine, will take power.'” [Tirmidhee] 
In another report, from Abū Hurairah, the Prophet ﷺ said, “If there were only one day left for this world, Allāh would lengthen it until he (the Mahdee) took power.” 
Abū Sa’eed said, “The Prophet ﷺ said, ‘The Mahdee will be one of my descendants; he will have a high forehead and a hooked nose. He will fill the earth with justice and fairness just as it was filled with injustice and oppression, and he will rule for seven years.'” [Abū Dawūd] 
Umm Salamah said, “I heard the Prophet ﷺ say,’The Mahdee will be one of my descendants, from the children of Faatimah.'” [Abū Dawūd] 
Umm Salamah reported that the Prophet ﷺ said, “People will begin to differ after the death of a Khaleefah. A man from the people of Madinah will flee to Makkah. Some of the people of Makkah will come to him and drag him out against his will; they will swear allegiance to him between al-Rukn and al-Maqam. An army will be sent against him from Syria; it will be swallowed up in the desert between Makkah and Madinah. When the people see this, groups of people from Syria and Iraq will come and swear allegiance to him. Then a man from Quraysh whose mother is from Kalb will appear and send an army against them, and will defeat them; this will be known as the Battle of Kalb. Whoever does not witness the spoils of this battle will miss much! The Mahdee will distribute the wealth, and will rule the people according to the Sunnah of the Prophet ﷺ. Then he will die, and the Muslims will pray for him.” [Abū Dawūd] 
6] Checker’s Note: “A man from my household…” Hasan, Saheeh al-Jami as-Sagheer: 8160.
7] at-Tirmidhee, in his chapters dealing with al-Fitan.
Checker’s Note: Saheeh, Saheeh at-Tirmidhee: 1819.
8] Abū Dawūd, Kitaab al-Mahdee.
Checker’s Note: Hasan, Saheeh Abū Dawūd: 3604. Translation states, “… a hooked nose.” Correct translation is “…an aquiline nose.”
9] Abū Dawūd, Kitaab al-Mahdee.
Checker’s Note: Saheeh, Saheeh Abū Dawūd: 3603.
10] Abū Dawūd, Kitaab al-Mahdee.
Checker’s Note: Da’eef, al-Mishkat, 1st checking: 5456.
¤Taken from the Signs Before the Day of Judgement
Alee said, “The Prophet ﷺ said, ‘A man named al-Haarith ibn Hirath will come from Transoxania. His army will be led by a man named Mansoor. He will pave the way for and establish the government of the family of Muhammad, just as Quraysh established the government of the Messenger of Allāh. Every believer will be obliged to support him.'” [Abū Dawūd] 
Abd Allaah ibn al-Haarith ibn Juz’ al-Zubaydee said, “The Prophet ﷺ said, ‘A people will come out of the East who will pave the way for the Mahdee.'” [Ibn Maajah] 
Abd Allaah said, “Whilst we were with the Prophet ﷺ, some young men from Banu Hashim approached us. When the Prophet ﷺ saw them, his eyes filled with tears and the colour of his face changed. I said, ‘We can see something has changed in your face, and it upsets us.’ The Prophet ﷺ said, ‘We are the people of a Household for whom Allāh has chosen the Hereafter rather than this world. The people of my Household (Ahl al-Bayt) will suffer a great deal after my death, and will be persecuted until a people carrying black banners will come out of the east. They will instruct the people to do good, but the people will refuse; they will fight until they are victorious, and the people do as they asked, but they will not accept it from them until they hand over power to a man from my household. Then the earth will be filled with fairness, just as it had been filled with injustice. If any of you live to see this, you should go to him even if you have to crawl across ice.'” 
This text refers to the rule of the Abbasids, as we have mentioned above in the text referring to the beginningof their rule in 132 AH. It also indicates that the Mahdee will appear after the Abbasids, and that he will be one of the Ahl al-Bayt, a descendant of Faatimah, the daughter of the Prophet ﷺ, through Hasan, not Husayn, as mentioned in the Hadeeth from Alee ibn Abee Taalib; and Allāh knows best. 
Thwaban said, “The Prophet ﷺ said, ‘Three men will be killed at the place where your treasure is. Each of them will be the son of a Khaleefah, and none of them will get hold of the treasure. Then the black banners will come out of the East, and they will slaughter you in a way which has never been seen before.’ Then he said something which I do not remember; then, ‘If you see him, go and give him your allegiance, even if you have to crawl over ice, because he is the Khaleefah of Allāh, the Mahdee.'” [Ibn Maajah] 
11] Checker’s Note: Da’eef, Da’eef al-Jami as-Sagheer: 6418.
12] Ibn Maajah, Kitaab al-Fitan (Hadeeth 3088).
Checker’s Note: Da’eef, Silsilatul Ahaadieeh ad-Da’eefah: 4826.
13] Ibn Maajah, ibid., (Hadeeth 4082).
Checker’s Note: Da’eef, Da’eef Ibn Maajah: 886.
14] See Ahaadeeth above. (Ref. 1, 2 & 3)
Checker’s Note: Footnote refers to hadeeth no. 3.
15] Narrated by Ibn Maajah, op. cit., Hadeeth 4084.
Checker’s Note: Da’eef Munkar (the isnaad is weak and moreover the meaning is wrong). In this case, the mention of “Khaleefah of Allāh” is munkar because Allāh cannot have a successor or vicegerent in His absence, Silsilatul Ahaadeeth ad-Da’eefah: 85
¤Taken from the Signs Before the Day of Judgement