The narrative begins in Venice, where the impoverished nobleman Bassanio needs a substantial loan to woo Portia, a wealthy heiress living in Belmont. Unable to secure the funds himself, his devoted merchant friend Antonio turns to the Jewish moneylender Shylock, who harbors a deep-seated hatred for Antonio due to his Christian intolerance and habit of lending money without interest. Shylock agrees to provide three thousand ducats on one condition: if the loan is not repaid by a specific date, Antonio must forfeit a pound of his own flesh from nearest his heart. Although the terms seem like a grim joke, Antonio signs the bond, confident his merchant ships will return with ample wealth well before the deadline.
Simultaneously, romantic entanglements unfold in Belmont, where suitors arrive to undergo a test devised by Portia's late father. They must choose correctly among three caskets made of gold, silver, and lead to win her hand. After several arrogant princes fail the test, Bassanio arrives and successfully chooses the leaden casket, winning Portia's love. Their celebration is cut short when news arrives from Venice that all of Antonio's merchant ventures have perished at sea, rendering him unable to repay the debt. Shylock, infuriated by the elopement and conversion of his daughter Jessica with a Christian, relentlessly pursues the literal fulfillment of the contract in court.
As the Duke of Venice convenes the court, appeals for mercy fall on deaf ears as Shylock fiercely demands his legal right to the forfeiture. Portia arrives disguised as a learned young doctor of laws, accompanied by her maid Nerissa disguised as a clerk, to intercede on Antonio's behalf. Initially acknowledging that the strict letter of Venetian law supports the bond, Portia urges Shylock to show mercy, but he refuses. Just as Shylock prepares to claim his pound of flesh, Portia turns the law against him by noting that the contract permits only flesh and allows for not a single drop of shedding blood, while demanding the exact weight under penalty of death and confiscation of property.
Trapped by his own insistence on strict justice, Shylock is stripped of his wealth, forced to surrender half his estate to the state and half to Antonio, and compelled to convert to Christianity. Antonio magnanimously waives his share of the penalty on the condition that Shylock bequeaths his remaining fortune to Lorenzo and Jessica upon his death. Meanwhile, Portia and Nerissa extract rings from their new husbands as supposed payment, setting up a final comedic confrontation in Belmont where the disguised wives playfully torment the men before revealing their clever deception.