An-Nisa 4:92
وَمَا كَانَ لِمُؤْمِنٍ أَن يَقْتُلَ مُؤْمِنًا إِلَّا خَطَـًٔا ۚ وَمَن قَتَلَ مُؤْمِنًا خَطَـًٔا فَتَحْرِيرُ رَقَبَةٍ مُّؤْمِنَةٍ وَدِيَةٌ مُّسَلَّمَةٌ إِلَىٰٓ أَهْلِهِۦٓ إِلَّآ أَن يَصَّدَّقُوا۟ ۚ فَإِن كَانَ مِن قَوْمٍ عَدُوٍّ لَّكُمْ وَهُوَ مُؤْمِنٌ فَتَحْرِيرُ رَقَبَةٍ مُّؤْمِنَةٍ ۖ وَإِن كَانَ مِن قَوْمٍۭ بَيْنَكُمْ وَبَيْنَهُم مِّيثَـٰقٌ فَدِيَةٌ مُّسَلَّمَةٌ إِلَىٰٓ أَهْلِهِۦ وَتَحْرِيرُ رَقَبَةٍ مُّؤْمِنَةٍ ۖ فَمَن لَّمْ يَجِدْ فَصِيَامُ شَهْرَيْنِ مُتَتَابِعَيْنِ تَوْبَةً مِّنَ ٱللَّهِ ۗ وَكَانَ ٱللَّهُ عَلِيمًا حَكِيمًا
Wama kana limu/minin anyaqtula mu/minan illa khataan waman qatala mu/minankhataan fatahreeru raqabatin mu/minatin wadiyatunmusallamatun ila ahlihi illa an yassaddaqoofa-in kana min qawmin AAaduwwin lakum wahuwa mu/minun fatahreeruraqabatin mu/minatin wa-in kana min qawmin baynakumwabaynahum meethaqun fadiyatun musallamatun ilaahlihi watahreeru raqabatin mu/minatin faman lam yajid fasiyamushahrayni mutatabiAAayni tawbatan mina Allahi wakanaAllahu AAaleeman hakeema
And never is it for a believer to kill a believer except by mistake. And whoever kills a believer by mistake - then the freeing of a believing slave and a compensation payment [diyah] presented to his [i.e., the deceased's] family [is required], unless they give [up their right as] charity. But if he [i.e., the deceased] was from a people at war with you and he was a believer - then [only] the freeing of a believing slave; and if he was from a people with whom you have a treaty - then a compensation payment presented to his family and the freeing of a believing slave. And whoever does not find [one or cannot afford to buy one] - then [instead], a fast for two months consecutively, [seeking] acceptance of repentance from Allāh. And Allāh is ever Knowing and Wise.
It is not for a believer (Muslim) to kill any believer, except by mistake. Whoever kills a believer by mistake, then, a believing slave has to be freed, and the blood money must be paid to his family, unless they forgo it.If he (the victim) belongs to a people hostile to you and is a believer, then, a believing slave has to be freed. If he (the victim) belongs to a people between whom and you there is treaty, then, blood money is to be paid to his family, and a believing slave to be freed. Whoever does not find one has to fast for two consecutive months. This is repentance prescribed from Allah’s side. Allah is All-Knowing, All-Wise.