Act IV, Scene One:
Antonio is brought before the Duke and the magnificoes of Venice to stand trial for failing to pay off his obligation to Shylock. The Duke is upset about the penalty, a pound of Antonio's flesh, but cannot find any lawful way of freeing Antonio from his bond. Shylock enters the court and the Duke tells him that all of the men gathered there expect him to pardon Antonio and forgive the debt.
Shylock replies that he has already sworn by his Sabbath that he will take his pound of flesh from Antonio. He is unable to provide a good reason for wanting to punish Antonio in this manner, other than to say, "So can I give no reason, nor I will not, / More than a lodged hate and a certain loathing / I bear Antonio" (4.1.58-60).
Bassanio then comes forward and offers Shylock the six thousand ducats as repayment for the loan. Shylock tells him that even if there were six times as much money offered to him, he would not take it. The Duke asks Shylock, "How shalt thou hope for mercy, rend'ring none?" (4.1.87). Shylock responds that he is doing nothing wrong, and compares his contract with Antonio to the Christian slave trade. He tells the Duke that he does not demand that the Christians should free their slaves, and therefore the Christians should not demand that he free Antonio.
The Duke threatens to dismiss the court without settling the suit brought by Shylock if Doctor Bellario fails to arrive. Salerio tells him that a messenger has just come from Bellario, and Nerissa enters dressed as a man and informs the Duke that Bellario has sent a letter to him. Shylock whets his knife on his shoe, confident that he will receive his pound of flesh.
The letter from Bellario recommends a young and educated doctor to arbitrate the case. The Duke asks where the young doctor is, and Nerissa tells him that he is waiting outside to be admitted into the court. The Duke orders him to be brought in, and Portiaenters dressed as a man, pretending to be a doctor named Balthasar.
Portia tells the Duke that she has thoroughly studied the case and then asks, "Which is the merchant here, and which the Jew?" (4.1.169). Antonio and Shylock both step forward, and Portia asks Antonio if he confesses to signing the contract. He does, and Portia then says that Shylock therefore must be merciful. She delivers a short speech on mercy, but Shylock ignores it and demands the contract be fulfilled. Portia then asks if no one has been able to repay the amount, but since Shylock has refused the money there is nothing she can do to make him take it. She comments that she must therefore side with Shylock.
Shylock, impressed that Portia is supporting his case, says, "A Daniel come to judgment, yea, a Daniel!" (4.1.218). Portia rules that Shylock has the right to claim a pound of flesh from next to Antonio's heart according to the bond. Antonio's bosom is laid bare and Shylock gets ready to cut. Portia asks him if he has a surgeon ready to stop the bleeding once he has taken his pound of flesh. Shylock says, "I cannot find it. 'Tis not in the bond" (4.1.257).
Just as Shylock is about to start cutting again, Portia says that the bond does not give him permission to shed Antonio's blood. The laws of Venice are such that if any Venetian's blood is shed, all the goods and lands of the perpetrator may be confiscated by the state. Shylock realizes that he cannot cut the flesh without drawing blood, and instead agrees to take the money instead. However, Portia is not willing to back down and instead only gives him the pound of flesh, further saying that if he takes a tiny bit more or less he will be put to death himself. Shylock, unable to comply with this stipulation, decides to withdraw his case.
Portia tells Shylock to remain in the court. She says that Venice has a further law which says that if any foreigner tries to kill a Venetian, the foreigner will have half of his property go to the Venetian against whom he plotted, and the state will receive the other half. In addition, the life of the foreigner will be in the hands of the Duke, who may decide to do whatever he wants to. Shylock is forced to kneel on the ground before the court, but the Duke pardons his life before he can beg for mercy.
Shylock instead asks the Duke to kill him, saying, "Nay, take my life and all, pardon not that. / You take my house when you do take the prop / That doth sustain my house; you take my life /When you do take the means whereby I live" (4.1.369-373). Antonio intervenes on Shylock's behalf, and asks the Duke to allow Shylock to keep half of his wealth. He further offers to take care of the half he was awarded as a form of inheritance for Jessica and Lorenzo. The only requirements Antonio puts on his offer are that Shylock must convert and become a Christian, and further that he must give everything he owns to Lorenzo upon his death.
Shylock, wretched and having lost everything he owns, tells the court that he is content to accept these conditions. The Duke leaves and tells Antonio to thank the young doctor who has saved his life. Bassanio and Graziano go to Portia and thank her profusely, and Bassanio offers the young doctor anything he wants. Portia decides to test her husband's trustworthiness, and asks him for the engagement ring, the ring which she made him vow never to part with. He refuses, and Portia and Nerissa leave. However, at Antonio's urging, Bassanio takes off the ring and gives it to Graziano, telling him to take it to Portia and invite her to dinner that night at Antonio's.
Act IV, Scene Two:
Portia gives Nerissa the deed by which Shylock will pass his inheritance to Lorenzo. She tells Nerissa to take it to Shylock's house and make him sign it. At the moment Graziano catches up with the two women and gives the ring to Portia. She is surprised that Bassanio parted with it after all, and Nerissa decides to test Graziano in the same way. Nerissa takes the deed and asks Graziano to show her the way to Shylock's house.