Qisas
Qisas or Qiṣāṣ () is an Islamic term interpreted to mean "retaliation in kind", "eye for an eye", or retributive justice. Qisas and diyya are two of several forms of punishment in classical/traditional Islamic criminal jurisprudence, the others being Hudud and Ta'zir. The legal systems of Iran, Pakistan, Saudi Arabia, United Arab Emirates, Qatar, and some Nigerian states currently apply qisas. History
A legal concept similar to qisas is the principle of "eye for an eye" first recorded in the Code of Hammurabi. Basis 

The main verse for implementation in Islam is Al Baqara; 178 verse;
: '''Believers! Retaliation is ordained for you regarding the people who were killed. Free versus free, captive versus captive, woman versus woman. Whoever is forgiven by the brother of the slain for a price, let him abide by the custom and pay the price well." In the tafsir (exogesis) of this verse, Mohammed Shafi' says: '...the one who has killed will be the one to be killed in Qisas قصاص . It is not permissible to kill an innocent man or someone free for a killer, woman or slave. Let us hasten to clarify that the verse does not mean that Qisas قصاص will not be taken from a man who kills a woman or from a free man who kills a slave. In the very beginning of this verse the words الْقِصَاصُ فِي الْقَتْلَى: "The Qisas قصاص has been enjoined upon you in the case of those murdered" are a clear proof of this universality of application. There are other verses where this aspect has been stated more explicitly, for instance, in النَّفْسَ بِالنَّفْسِ (the person for the person).' Another view: a member of the tribe to which the murderer belonged was handed over to the victim's family for execution, equivalent to the social status of the murdered person. The element of "intention" is taken into account in only one of the accusations in the Quran (killing and in a single case (a believers killing another believer) and in return for this, a slave should be freed and to the family of the killed one, should be paid "unspecified" financial compensation (diyya). However, in the continuation of the verse, another condition for financial compensation is considered. According to this, it is claimed that the deceased person must live in the same community with the believers or the society in which the deceased lives must have an agreement with the believers. The two-month fasting that the murderer will keep in case of financial inadequacy is considered sufficient as a reward for the crime (Surah Al-Nisa; 176). On the other hand, the later jurists  stipulates "the element of intent" in case of physical injury and killing acts as well as other conditions determined for bodily retaliation.Encyclopædia Britannica, Qisas (2012) 

The applicability of the punishment of qisas has been conditioned by the fiqhists on a large number of conditions, such as the innocence of the injured person or the victim. Injury which may be the subject of a qisas application may only be applied if there is a definite organ loss whose limits can be guaranteed that no more harm will be done to the offender than he has caused in the punishment. In this case, qisas cannot be made against the most common forms of killing and wounding that occur during ordinary daily fights using stone sticks, blades, and piercing tools. Because the qisas is the punishment of the offender exactly the same crime committed, for a person who is raped to death or beheaded, the plain death sentence to be given to the murderer does not mean that qisas has been fulfilled. Islamic scriptures

 Quran 
The qisas or equivalence verse in Quran is,

 
In the tasfir of this verse, Mohammed Shafi' provides context: 'On the authority of Ibn Abi Hatim ؓ 1, Ibn Kathir (رح) has reported that, just before the advent of Islam, war broke out between two tribes. Many men and women, free and slaves, belonging to both, were killed. Their case was still undecided when the Islamic period set in and the two tribes entered the fold of Islam. Now that they were Muslims, they started talking about retaliation for those killed on each side. One of the tribes which was more powerful insisted that they would not agree to anything less than that a free man for their slave and a man for their woman be killed from the other side. It was to refute this barbaric demand on their part that this verse was revealed. By saying 'free man for a free man, slave for a slave and female for a female' it is intended to negate their absurd demand that a free man for a slave and man for a woman should be killed in retaliation, even though he may not be the killer. The just law that Islam enforced was that the killer is the one who has to be killed in Qisas قصاص . If a woman is the killer why should an innocent man be killed in retaliation? Similarly, if the killer is a slave, there is no sense in retaliating against an innocent free man. This is an injustice which can never be tolerated in Islam.' The Quran allows the aggrieved party to receive monetary compensation (blood money, diyya, ) instead of qisas, or forfeit the right of qiṣāṣ as an act of charity or in atonement for the victim family's past sins. Hadith 

The Hadiths have extensive discussion of qisas. For example, Sahih Bukhari states,

Many premodern Islamic scholars ruled, based on hadith, that when the victim was a non-Muslim dhimmi or a non-Muslim slave owned by a Muslim, only diya (blood money) and not qisas should be available as compensation. Traditional jurisprudence

Classical/traditional Islamic jurisprudence (fiqh) treats homicide as a civil dispute between victim and perpetrator, rather than an act requiring corrective punishment by the state to maintain order. In all cases of murder, unintentional homicide, bodily injury and property damage, under classical/traditional Islamic law, the prosecutor is not the state, but only the victim or the victim's heir (or owner, in the case when the victim is a slave). Qisas can only be demanded by the victim or victim's heirs. Differences in treatment according to religion and status of victim

In the early history of Islam, there were considerable disagreements in Muslim judicial opinions on applicability of qisas and diyya when a Muslim murdered a non-Muslim (Dhimmi, Musta'min or slave).Tahir Wasti (2009), The Application of Islamic Criminal Law in Pakistan: Sharia in Practice, Brill, , pp. 89-90 (In yet another class were murdered apostates from and blasphemers of Islam, non-Muslims who does not enjoy the protection of a Muslim state under the status of a Dhimmi or Musta'min, etc.) According to classical jurists of three of the four Sunni Islamic schools of jurisprudence (Shafi'i, Maliki, and Hanbali schools), qisas is available only when the victim is Muslim;  while the Hanafi school holds it may apply in some circumstances when a Muslim has done harm to a non-Muslim.Rudolph Peters and Peri Bearman (2014), The Ashgate Research Companion to Islamic Law, , pp. 169-170

Jurists agree that neither qisas nor any other form of compensation applied in cases where the victim is 
an apostate (converted from Islam to another religion), 
a person who has committed the hadd crime of transgression against Islam or Imam (baghy), or 
a non-Muslim who does not enjoy the protection of a Muslim state under the status of a Dhimmi or Musta'min, or 
if the non-Muslim victim's family could not prove that the victim used to pay Jizya.Richard Terrill (2012), World Criminal Justice Systems: A Comparative Survey, Routledge, , pp. 554-562

Numerous Hanafi, Shafi'i and Maliki jurists stated that a Muslim and a non-Muslim are neither equal nor of same status under sharia, and thus the judicial process and punishment applicable must vary. This was justified by the hadith:

Hanafi
The Hanafi school ordains lesser-than-murder qisas across religions, whether the perpetrator is Muslim or non-Muslim, according to Sayyid Sabiq's Fiqh Sunnah. Most Hanafi scholars ruled that, if a Muslim killed a dhimmi or a slave, Qisas (retaliation) was applicable against the Muslim, but this could be averted by paying a Diyya.Rudolph Peters and Peri Bearman (2014), The Ashgate Research Companion to Islamic Law, , pp. 129-137 In one case, the Hanafi jurist Abu Yusuf initially ordered Qisas when a Muslim killed a dhimmi, but under Caliph Harun al-Rashid's pressure replaced the order with Diyya if the victim's family members were unable to prove the victim was paying jizya willingly as a dhimmi. According to Fatawa-e-Alamgiri, a 17th-century compilation of Hanafi fiqh in South Asia, a master who kills his slave should not face capital punishment under the retaliation doctrine. If a Muslim or a dhimmi killed a Musta'min (foreigner visiting) who did not enjoy permanent protection in Dar al-Islam and might take up arms against Muslims after returning to his homeland (dar al-harb),  neither Qisas nor Diyya applied against  the Musta'min's murderer according to Hanafi fiqh according to Yohanan Friedmann. But Abdul Aziz bin Mabrouk Al-Ahmadi narrates that the Hanafi scholars say that Musta'min is entitled to Diyya equal to Diyya  of a Muslim, and he quotes this opinion from a group of other muslim scholars, including a some of Companions of the Prophet, and he also narrates that this is one of the opinions of the Hanbalis if the killing occurred intentionally. Non-Hanafi 
Non-Hanafi jurists have historically ruled that qisas does not apply against a Muslim, if he murders any non-Muslim (including dhimmi) or a slave for any reason. Instead, the schools impose Diyya on the perpetrator. Both Shafi'i and Maliki fiqh doctrines maintained that the qisas applies only when there is "the element of equality between the perpetrator and the victim", according to scholar Yohanan Friedmann. Since "equality does not exist between a Muslim and an infidel, [because] Muslims are exalted above the infidels", qisas is not available to an infidel victim when the crime's perpetrator is a Muslim. In Shafi'i fiqh, this inequality was also expressed in diyya compensation payment to the heirs of a dhimmi victim's which should be a third of what would be due in case the victim was a Muslim. In Maliki fiqh, compensation for a non-Muslim in the case of unintentional killing, bodily or property damage should be half of what would be due for an equivalent damage to a Muslim. Maliki fiqh does made an exception to the ban on applying qisas against a Muslim when their victim is a dhimmi in cases where the murder of the dhimmi is treacherous in nature. According to Hanbali legal school, if a Muslim kills or harms a non-Muslim, even if intentionally, qisas does not apply, and the sharia court may only impose a diyya (monetary compensation) with or without a prison term on the Muslim at its discretion. Current practiceQiṣāṣ is currently provided for by legal systems of several countries which apply classical/traditional Islamic jurisprudence (Saudi Arabia) or have enacted qisas laws as part of modern legal reforms. Iran
Iran's penal code includes qisas as a method of punishment, spelled out in sections 1 through 80 of the code.Islamic Penal Code of the Islamic Republic of Iran , Book 3 The penal code outlines two types of Qisas crime - Qisas for when a life has been lost, and Qisas when a part of a human body has been lost. In cases of qisas for life, the victim's family may with the permission of court, take the life of the murderer. In cases of qisas for part of a human body, section 55 of Iran's penal code grants the victim or victim's family to inflict an equal injury to the perpetrator's body, provided they are given permission by the court. (The code also spells out what to do in different circumstances. If the victim lost the right hand and perpetrator does not have a right hand for qisas, for example, then with court's permission, the victim may cut the left hand of the perpetrator.) In one episode, qiṣāṣ was demanded by Ameneh Bahrami, an Iranian woman blinded in an acid attack. She demanded that her attacker Majiv Movahedi be blinded as well. In 2011, Bahrami retracted her demand on the day the sentence was to be carried out, requesting instead that her attacker be pardoned. A prisoner lodged in the Gohardasht Prison of the city of Karaj, was reported to have been blinded in March 2015 after being convicted for an acid attack on another man in 2009 and sentenced to the punishment under "qisas". Cases where qisas has been sentenced as a punishment, but the sentence not (as of November 2021) yet carried out, include: 
the October 2021 sentencing a 45-year-old man to forced blinding by a Criminal Court in Tehran after his neighbor lost his right eye as a result of a fight with the man in June 2018; 
the February 2021 sentencing to amputation (and other punishment) of a man in Chaharmahal and Bakhtiari province in southwestern Iran, as a result of injuring a state environmental agent; 
the May 2020 sentence of blinding in both eyes of a 30-year-old woman in northeastern Iran who had blinded a man by throwing acid on his face. Pakistan
Pakistan introduced qisas and diyya (diyat) in 1990 as Criminal Law (Second Amendment) Ordinance, after the Shariat Appellate Bench of the Supreme Court of Pakistan declared that the lack of qisas and diyat were repugnant to the injunctions of Islam as laid down by the Quran and Sunnah. Pakistani parliament enacted the law of Qisas and Diyat as Criminal Law (Amendment) Act, 1997. An offender may still be punished despite pardoning by way of ta'zīr or if not all the persons entitled to Qisas joined in the compromise. The Pakistan Penal Code modernized the Hanafi doctrine of qisas and diya by eliminating distinctions between Muslims and non-Muslims. Nigeria
Since the 1960s, several northern states of Nigeria have enacted sharia-based criminal laws, including provisions for qisas. These codes have been applied in the Sharia Courts of Nigeria to Muslims. Many have been sentenced to retaliation under the qisas principle, as well as to other punishments such as hudud and tazir.I.K. Oraegbunam (2012), Penal Jurisprudence under Islamic Criminal Justice: Implications for the Right to Human Dignity in Nigerian Constitution, Journal Islamic State Practices in Int'l Law, 8, pp. 31-49

Saudi Arabia
Murder and manslaughter are private offenses in Saudi Arabia, which a victim or victim's heirs must prosecute, or accept monetary compensation, or grant pardon. The sharia courts in Saudi Arabia apply Qisas to juvenile cases, with previous limit of 7 year raised to 12 year age limit, for both boys or girls. This age limit is not effectively enforced, and the court can assess a child defendant's physical characteristics to decide if he or she should be tried as an adult. In most cases, a person who satisfies at least one of the following four characteristics is considered as an adult for qisas cases: (1) above the age of 15, (2) has wet dreams (al-ihtilam), (3) any appearance of pubic hair, or (4) start of menstruation. Qisas principle, when enforced in Saudi Arabia, means equal retaliation and damage on the defendant. According to reports in Saudi media, in 2013, a court in Saudi Arabia sentenced a defendant to have his spinal cord severed to paralyze him, unless he paid one million Saudi riyals (about US$270,000) in Diyya compensation to the victim. The offender allegedly stabbed his friend in the back, rendering him paralysed from the waist down in or around 2003. Other reported sentences of qisas in KSA have included eye gouging, tooth extraction, and death in cases of murder. Qisas and honor crimes

According to most variations of Islamic Law, qisas does not apply if a Muslim parent or grandparent kills their child or grandchild, or if the murder victim is a spouse with whom one has surviving children. The culprit can be, however, subject to Diyya (financial compensation) which is payable to the surviving heirs of the victims or punished through Tazir which is a Fixed punishment given by the Judge or Ruler. The four major schools of Sunni Sharia have been divided on applicability of qisas when the victim is a child, and the father is the murderer. The Hanafi, Shafi'i, and Hanbali Sunni sharias have ruled that qisas does not apply, as has the Shia Sharia doctrine. The Maliki school, however, has ruled that qisas may be demanded by the mother if a father kills his son.Tahir Wasti (2009), The Application of Islamic Criminal Law in Pakistan: Sharia in Practice, Brill, , p. 90 The Hanafi, Hanbali and Shafi'i sharia extend this principle to cases when the victim is a child and the mother or grandparents are the murderers.Tahir Wasti (2009), The Application of Islamic Criminal Law in Pakistan: Sharia in Practice, Brill, 

Some suggest that this exemption of parents and relatives from Qisas, and the treatment of homicide-related qisas as a civil dispute that should be handled privately by victim's family under sharia doctrine, encourages honor crimes, particularly against females, as well as allows the murderer(s) to go unpunished.RA Ruane (2000), Murder in the Name of Honor: Violence Against Women in Jordan and Pakistan. Emory Int'l Law Review, 14, pp. 1523-1532 This, state Devers and Bacon, is why many honor crimes are not reported to the police, nor handled in the public arena.Sharbanoo Keshavarz (2006), Honor Killing in Iran: a Legal Point of View, Yearbook of Islamic & Middle East Law (2006-2007), Vol 13, pp. 87-103 However, if the killer was proven to have accused the victim of adultery, a false accusation of rape case can be raised and the sentence carried out. Furthermore, relations between the Islamic law and honor killing might be somewhat off since the tradition of honor killings also occurs and encouraged in non-Muslim world, even the Western one. Historically, Sharia did not stipulate any capital punishment against the accused when the victim is the child of the murderer, but in modern times some Sharia-based Muslim countries have introduced laws that grant courts the discretion to impose imprisonment of the murderer. However, the victim's heirs have the right to waive qisas, seek diyat'', or pardon the killer. See also 
Sabr
Sharia
 Hudud
 Tazir
 Diyya
 Application of sharia law by country

References 

Arabic words and phrases in Sharia
Islamic criminal jurisprudence
Punishments in religion
Islam and violence
Islam and capital punishment
Sharia legal terminology