عَنْ ابْنِ مَسْعُودٍ رَضِيَ اللهُ عَنْهُ قَالَ: قَالَ رَسُولُ اللَّهِ صلى الله عليه و سلم لَا يَحِلُّ دَمُ امْرِئٍ مُسْلِمٍ إلَّا بِإِحْدَى ثَلَاثٍ: الثَّيِّبُ الزَّانِي، وَالنَّفْسُ بِالنَّفْسِ، وَالتَّارِكُ لِدِينِهِ الْمُفَارِقُ لِلْجَمَاعَةِ
Meaning: The Messenger of Allah ﷺ said: The blood of a Muslim person may not be shed except in one of three cases: the married person who commits adultery, a life for a life, and one who abandons his religion and separates from the community.
Sahih: agreed upon by al-Bukhari and Muslim.
Narrated by Abdullah ibn Mas'ud · Sahih al-Bukhari 6878; Sahih Muslim 1676