In the mid-1930s, journalist-turned-novelist James M. Cain wrote a novella about an insurance salesman who falls for another man’s wife, and agrees to help her kill him so they can be together. The story quickly made its way to Hollywood, where the strict moral guidelines of the Production Code placed it on the back burner. Eventually, the story made its way into the hands of then-fledgling director Billy Wilder, who saw something special in it.

Double Indemnity had to fight objections to its content, two screenwriters who hated working together, two stars who weren’t sure they could handle their respective roles, and an ending that had to be changed. But when it finally got released in 1944, film history was made.

The film is a masterpiece in the filmographies of Wilder and stars Barbara Stanwyck and Fred MacMurray, and is arguably the first true example of that classic Hollywood subgenre known as film noir. In celebration of its greatness, here are 10 facts about how Double Indemnity got made, and what came after.

1. IT WAS INSPIRED BY A REAL MURDER.

Before he began making serious headway as a writer of fiction, Double Indemnity author James M. Cain worked as a journalist in New York, and it was there that he stumbled upon the real-life murder case of Albert Snyder, who was killed in 1927 by his wife, Ruth Brown Snyder, and her lover, a corset salesman named Henry Judd Gray. Before committing the murder, Brown took out a $100,000 life insurance policy on her husband, then tried to kill him several times, but was unsuccessful. She ultimately turned to Gray for help in the murder plot, and both were ultimately executed for the murder in 1928.

Cain used the case as the inspiration for two of his earliest and most famous stories. His first novel, 1934's The Postman Always Rings Twice, is about a man who falls in love with a beautiful woman and then helps her—unsuccessfully, at first—murder her older husband. The novel quickly made its way to Hollywood, where the Hays Production Code—which provided moral oversight for movie production—was just beginning to be strictly enforced, so the story languished without a film adaptation for years.

In the meantime, Cain wrote Double Indemnity, another story of a man swept up in a plot to murder his lover’s husband, this time with an insurance scam added. The story was serialized in the pages of Liberty magazine in 1936, but was first submitted as a potential Hollywood property in 1935. Double Indemnity finally made it to the screen in 1944, and The Postman Always Rings Twice followed with its own well-received film version in 1946. (It was remade in 1981 with Jack Nicholson and Jessica Lange, from a script by David Mamet.)

2. IT FOUGHT THE PRODUCTION CODE FOR YEARS.

Universal Pictures Home Entertainment

Double Indemnity was first placed before the Production Code Administration in Hollywood in 1935, the year before it was serialized in Liberty, and the story was immediately met with resistance from PCA head Joseph I. Breen, who noted that a film version would likely be rejected according to the code. Among Breen’s concerns in a 1935 letter that eventually made its way to various studios interested in the property were that "the leading characters are murderers who cheat the law and die at their own hands (Cain’s original story features a double suicide); the story deals improperly with an illicit and adulterous sex relationship; [and] the details of the vicious and cold-blooded murder are clearly shown."

It took eight years for someone to come up with a version of the story that Breen could finally approve, and he wrote to Paramount Pictures—the studio that eventually made Double Indemnity—in 1943 with a few final notes to ensure that the apparently “acceptable” script would pass muster, including making sure Phyllis’s towel covered her enough during her entrance, and ensuring that the actual murder sequence didn’t show too much of the deed itself or the disposal of the corpse (the famous murder sequence ultimately features a close-up of Barbara Stanwyck’s face as the deed is done off-camera). So, after nearly a decade of struggling against the restrictions of the Production Code, Double Indemnity was finally able to move forward.

3. BILLY WILDER’S WRITING PARTNER AT THE TIME TURNED IT DOWN.

It was producer Joseph Sistrom who first brought Double Indemnity to Wilder, believing the filmmaker would respond well to Cain’s hard-boiled story of deception and seduction. Wilder did indeed respond well to the film, and took it on as what was, at the time, only his third Hollywood effort as a director after years of mostly screenwriting work. Wilder, a firm believer in two heads being better than one during the screenwriting process, wanted to work on the Double Indemnity script with collaborator Charles Brackett, with whom he’d already written eight films, including Ninotchka (1939) and his most recent directorial effort Five Graves to Cairo (1943). Brackett declined to work on the film, though, citing the scandalous and amoral nature of its story as reasons for his reluctance to take it on.

When searching for a new collaborator, Wilder initially thought of hiring Cain, who was by then already working in Hollywood, but he was occupied at another studio. A friend of Wilder’s suggested Raymond Chandler, whose writing style and knack for dialogue was similar to Cain’s, and Wilder agreed. After Double Indemnity, Brackett would continue to collaborate with Wilder, and the two produced classics like The Lost Weekend (1945), A Foreign Affair (1948), and Sunset Boulevard (1950).

4. WILDER AND RAYMOND CHANDLER HATED WORKING TOGETHER.

Wilder agreed to work with Chandler after reading some of his prose and finding the future author of The Long Goodbye had a knack for clever lines of dialogue and description. Chandler had never written a script, though, and according to Wilder the pulp legend did not understand that the screenwriting process was one that took several months. Instead, Chandler asked for a script on a Friday to familiarize himself with the format, and promised Wilder a draft “a week from Monday.” When Chandler returned with the work he’d done, Wilder declared it “absolute bullshit,” and the two began working together on the script, writing together in an office for about eight hours a day.

Once the two legends settled into close quarters, though, they found that they quickly got on each other’s nerves. Chandler, an alcoholic, was sober at the time the collaboration began, and was annoyed that Wilder would drink around him. Wilder, for his part, kept excusing himself ostensibly to go to the bathroom, but in reality he simply wanted to take frequent breaks from Chandler’s presence. At one point, Chandler drafted a memo to the studio listing his various grievances with his writing partner, including the fact that Wilder wore his trademark hat indoors.

Somehow, though, after several months of work, the pair produced an Oscar-nominated script, and Wilder was pleased with Chandler’s contributions, even though the process was strained.

“I had to explain a lot to him as we went along, but he was very helpful to me,” Wilder recalled. “What we were doing together had real electricity. He was a very, very good writer—but not of scripts."

5. NO ONE WANTED TO PLAY WALTER NEFF.

After the project had weathered the Production Code and the laborious screenwriting process, Wilder hit even more snags when it came to casting. According to Wilder, “everybody turned [him] down” when he was looking for a leading man to play insurance salesman-turned-killer Walter Neff, including crime drama stars Alan Ladd and George Raft, who asked Wilder where “the lapel” in the film was, meaning the moment when Neff would flip over his lapel and reveal a badge. Wilder said no lapel moment was forthcoming, so Raft turned him down.

Wilder then approached Fred MacMurray, an actor then best known for lighter fare. MacMurray protested that he was the kind of actor who made “little comedies,” but Wilder talked him into it, and MacMurray ultimately looked back on Neff as one of his greatest roles.

6. BARBARA STANWYCK WAS SCARED TO PLAY PHYLLIS DIETRICHSON.

Universal Pictures Home Entertainment

Neff was not the only role Wilder ran into difficulty with. He wanted Barbara Stanwyck—then the highest-paid actress in Hollywood—to play the role of seductress and murderess Phyllis Dietrichson. Stanwyck was a serious, acclaimed actress with two Oscar nominations to her name already, but the idea of playing such a dark role was intimidating to her. Wilder appealed to her competitive nature, and asked, "Well, are you a mouse or an actress?" Stanwyck wasn’t about to let a remark like that drive her away from a part, so she took the role, and earned her third Best Actress nomination—and a place as one of cinema’s greatest femme fatales in the process.

7. STUDIO EXECUTIVES HATED STANWYCK’S WIG.

Stanwyck’s performance in Double Indemnity was hailed as one of her best even in 1944, when critics and executives were finally seeing the completed film, but there was one complaint that kept going around, and that some viewers still notice: her hair. Though it may seem like an immovable part of the film now, the blonde wig Phyllis wears was a noticeable change to Stanwyck’s overall look at the time, and some viewers complained that it looked too cheap and fake. One executive at Paramount, after seeing some early footage, commented: "We hire Barbara Stanwyck and here we get George Washington."

Having Stanwyck go blonde for the film was Wilder’s idea, and while he told people for years that the wig was chosen to intentionally convey something showy and even trashy about Phyllis, he later admitted that was just the answer he made up after realizing he made a mistake with the choice of wig a bit too late.

“But after the picture is half-finished, after I shot for four weeks with Stanwyck, now I know I made a mistake. I can't say, ‘Look tomorrow, you ain't going to be wearing the blonde wig.’ I'm stuck ... I can't reshoot four weeks of stuff. I'm totally stuck. I've committed myself; the mistake was caught too late. Fortunately it did not hurt the picture. But it was too thick, we were not very clever about wig-making. But when people say, ‘My god, that wig. It looked phony,’ I answer ‘You noticed that? That was my intention. I wanted the phoniness in the girl, bad taste, phony wig.’ That is how I get out of it.”

8. THE ORIGINAL ENDING FEATURED NEFF’S EXECUTION.

Cain’s original novella ends with the two lovers committing suicide together, but since suicide was forbidden by the Production Code, Wilder and Chandler had to develop an alternate ending, and came up with the notion that Neff would shoot Phyllis after she wounds him, and he would then return to the insurance office to record his confession, only to be discovered by Barton Keyes, a claims adjuster and co-worker. The film famously ends with Walter collapsed on the floor, with Keyes lighting a cigarette for him as sirens approach outside, but the original script actually went further, showing Neff’s arrest and his eventual execution in a gas chamber. Wilder even shot the gas chamber ending, but cut it for two reasons: The PCA was concerned the details were too gruesome, and Wilder himself felt that it was ultimately unnecessary to the story.

“I shot that whole thing in the gas chamber, the execution, when everything was still, with tremendous accuracy. But then I realized, look this thing is already over. I just already have one tag outside that office, when Neff collapses on the way to the elevator, where he can’t even light the match,” he recalled. “And from the distance, you hear the sirens, be it an ambulance or be it the police, you know it is over. No need for the gas chamber."

9. WILDER WAS VERY FRUSTRATED BY THE FILM’S OSCAR LOSSES.

Double Indemnity was nominated for seven Oscars in 1945, including Best Picture, Best Director, Best Screenplay, and Best Actress. It won none of these awards, and lost several to eventual Best Picture winner Going My Way. When Leo McCarey was announced as that year’s Best Director winner for his work on Going My Way, Wilder had had enough of losing. As McCarey passed him, according to film noir historian Eddie Muller, Wilder stuck out his foot and tripped him, sending him sprawling in the aisle before he collected himself and went up to claim his trophy.

10. THERE ARE THREE OTHER ADAPTATIONS.

Though its journey to the screen was long, Double Indemnity was critically acclaimed upon release, and quickly developed a reputation as a classic. Today it stands as an essential film for fans of Wilder, Stanwyck, and MacMurray, as well as a seminal piece of film noir. That didn’t stop other adaptations of Cain’s novel from trying to replicate some of that success, though. Stanwyck and MacMurray returned to their respective roles for a radio broadcast of the story in 1950, and Double Indemnity was adapted for television twice, first by NBC in 1954 and then by ABC in 1973. When the latter was broadcast, Wilder called up Stanwyck after it aired—according to USC School of Cinema-Television professor Dr. Drew Casper, who was with Stanwyck at the time—and said, “They didn’t get it right.”

Additional Sources: Shadows of Suspense (2006)