Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:2:108

Or do you intend to ask your Messenger as Moses was asked before? And whoever exchanges faith for disbelief has certainly strayed from the soundness of the way.  

When the Meccans asked ˹the Prophet˺ to enlarge the size of Mecca and make Safā full of gold, the following was revealed: Or do you desire to question your Messenger as Moses was questioned, by his people, aforetime?, when they asked him to show them God openly among other things; whoever exchanges belief for unbelief, taking the latter in place of the former by refraining from contemplating the clear proofs and by requesting others instead, has surely strayed from the even way, meaning, he has mistaken the proper path (al-sawā‘ essentially means al-wasat, ‘middle way’).
القرآن:٢:١٠٨

أَمْ تُرِيدُونَ أَنْ تَسْأَلُوا رَسُولَكُمْ كَمَا سُئِلَ مُوسَىٰ مِنْ قَبْلُ ۗ وَمَنْ يَتَبَدَّلِ الْكُفْرَ بِالْإِيمَانِ فَقَدْ ضَلَّ سَوَاءَ السَّبِيلِ  

{أم} بل {تريدون أن تسألوا رسولكم كما سئل موسى} أي سأله قومه {من قبل} من قولهم: أرنا الله جهرة وغير ذلك {ومن يتبدل الكفر بالإيمان} أي يأخذ بدله بترك النظر في الآيات البينات واقتراح غيرها {فقد ضل سواء السبيل} أخطأ الطريق الحق والسواءُ في الأصل الوسط.