Mishkat al-Masabih 973
Zaid b. Thabit said:
We were commanded to say after every prayer, 'Glory be to God’ thirty-three times, ‘Praise be to God’ thirty-three times, and ‘God is most great’ thirty-four times. One of the Ansar had a vision in sleep in which he was asked, “Has God’s Messenger commanded you to say ‘Glory be to God’ such and such a number of times after every prayer?” When the Ansari replied in his sleep that that was so, the visitant said, “Do it twenty-five times, and join to it ‘There is no god but God’ twenty-five times.” In the morning, when he went and told the Prophet, he said, “Do so."

Ahmad, Nasa’i and DarimI transmitted it.
وَعَن زيد بن ثَابت قَالَ: أُمِرْنَا أَنْ نُسَبِّحَ فِي دُبُرِ كُلِّ صَلَاةٍ ثَلَاثًا وَثَلَاثِينَ وَنَحْمَدَ ثَلَاثًا وَثَلَاثِينَ وَنُكَبِّرَ أَرْبَعًا وَثَلَاثِينَ فَأُتِيَ رَجُلٌ فِي الْمَنَامِ مِنَ الْأَنْصَارِ فَقِيلَ لَهُ أَمَرَكُمْ رَسُولُ اللَّهِ صَلَّى الله عَلَيْهِ وَسلم أَن تسبحوا فِي دبر كُلِّ صَلَاةٍ كَذَا وَكَذَا قَالَ الْأَنْصَارِيُّ فِي مَنَامِهِ نَعَمْ قَالَ فَاجْعَلُوهَا خَمْسًا وَعِشْرِينَ خَمْسًا وَعِشْرِينَ وَاجْعَلُوا فِيهَا التَّهْلِيلَ فَلَمَّا أَصْبَحَ غَدَا عَلَى النَّبِيِّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ فَأَخْبَرَهُ فَقَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «فافعلوا» . رَوَاهُ أَحْمد وَالنَّسَائِيّ والدارمي