Amateur tennis star Guy Haines (Farley Granger) wants to marry Anne Morton (Ruth Roman), the daughter of a senator, and pursue a political career. First, he must divorce his vulgar and promiscuous wife Miriam (Laura Elliott). On a train, Bruno Anthony (Robert Walker) recognizes Guy and knows about his marital situation from the gossip pages. Bruno introduces himself, then proposes an idea for the perfect homicide: he and Guy should "swap murders". Bruno will murder Miriam, and in exchange Guy will kill Bruno's despised father. Each would be killing a stranger. Having no identifiable motive for the crimes, neither would be suspects. Guy humors Bruno's absurd murder plot by pretending to find it amusing. Bruno interprets this as agreement to the scheme. Bruno then borrows Guy's monogrammed cigarette lighter and slips it into his own pocket.
Guy meets with Miriam. Pregnant by someone else, she now refuses to give Guy a divorce and threatens to cause a scandal. Guy relays the bad news to Anne, metaphorically commenting that he would like to "strangle" Miriam. Meanwhile, Bruno stalks Miriam through an amusement park and fatally strangles her on the "Magic Isle". Bruno then informs Guy that Miriam is dead, and expects him to follow through on murdering Bruno's father. Bruno sends Guy his house key, a map to his father's bedroom, and a pistol.
When the police question Guy about Miriam's death, he claims he was on a train at the time of the murder. The police determine his alibi is inconclusive because he could have left the train in time to commit the murder and continued his trip on another train. Guy is not arrested, but the police assign an officer to trail him to ensure he does not flee while they investigate.
To pressure Guy into fulfilling his obligation, Bruno introduces himself to Anne and meets Anne's younger sister, Barbara (Patricia Hitchcock), who physically resembles Miriam. Soon after, Bruno appears uninvited at a party at Senator Morton's house. To amuse another guest, Bruno demonstrates how to fatally strangle someone. His gaze happens to fall upon Barbara, and her resemblance to Miriam triggers a flashback. He begins strangling the woman but he blacks out before harming her. An upset Barbara tells Anne that, "His hands were on her throat, but he was strangling me." Anne confronts Guy, who confesses the truth about Bruno's crazy scheme.
Pretending to agree to Bruno's original plan, Guy sneaks into Mr. Anthony's bedroom intending to warn him of his son's murderous intent. It is Bruno who is waiting there, however. Guy tries to convince Bruno to seek psychiatric help. When Guy refuses to follow through with Bruno's plan, Bruno threatens to frame Guy for Miriam's murder.
Anne visits Bruno's mother (Marion Lorne) to tell her that her son committed a murder, but the befuddled woman discounts it. Bruno appears and informs Anne that he intends to incriminate Guy by planting the stolen cigarette lighter at the amusement park. Anne and Guy devise a plan for Guy to finish his tennis match, evade the police, and reach the amusement park to prevent Bruno from planting the lighter.
Guy eventually wins the long match at Forest Hills, then, eluding the police, heads for the amusement park. Bruno is also delayed when he accidentally drops Guy's lighter down a storm drain and has to recover it. Guy arrives at the amusement park. Bruno stays out of sight until sunset when he can plant the lighter on the "Magic Isle". A worker recognizes Bruno from the night of the murder and informs the police. Guy catches up to Bruno, and they fight on the park's carousel. Thinking Guy is trying to escape, a police officer shoots at him, but his shot misses and kills the carousel operator instead. The dead man falls onto the control panel, and the carousel spins wildly out of control and crashes. The worker who recognized Bruno tells the police that Guy is innocent, and the mortally injured Bruno is the man he saw that night. Guy tells the police that Bruno was attempting to plant Guy's lighter at the murder scene. Bruno refuses to clear Guy, but as he dies, his fingers open to reveal Guy's lighter.
Output: What does Bruno Anthony want Guy Haines to do in exchange for his murdering Haines' wife Miriam?