In 1967, Ira Levin was already, by most anyone’s standards, a very, very successful writer. At 21, he’d sold two TV scripts to NBC; soon after, a Broadway play garnered a Tony nod and his first novel—in which a ruthless young man murders his pregnant lover—won the 1954 Edgar Award. But with every hit came a flop, and success always seemed to come with a cost—a theme rooted deeply in all his best works, especially Rosemary’s Baby.

A hit novel turned iconic film, Rosemary’s Baby was a massive success that, according to half a century of pop-culture lore, is also cursed. Did Levin’s tale of lapsed-Christian Rosemary, who unknowingly carries and births the devil in return for her actor husband’s stage success, really jinx all those who got near it? And if so, why did Levin himself stay so seemingly unscathed?

Like all good scary stories, this one starts out very ordinary. In 1965, struggling as always for his next big idea, Levin looked no further than his pregnant wife in their New York apartment. He plopped every would-be parent’s feelings of anxiety atop an imminent historical moment: June 1966, or 666—a.k.a. the “number of the beast,” as predicted in the New Testament’s Book of Revelation. Religious counterculture was already swirling: the Church of Satan was soon to be established in San Francisco, and in April 1966 Time magazine had just famously asked on its cover: “Is God Dead?”

Levin went even darker: What if he took the birth of Jesus and turned the whole tale upside down? What if God was not only dead but the devil lived?

A Jewish atheist, Levin nonetheless wrote with mounting reservations. He was “sort of taking notes,” he said, of his wife’s progress alongside Rosemary’s, but flatly refused to let her read the manuscript. His fears were both personal and professional; the book was blasphemy, perhaps, and Levin feared backlash, blacklisting from publishers, or much worse.

Published 50 years ago this spring, Rosemary’s Baby was instead immediately declared perfect, the best horror novel ever crafted, a modern masterpiece. Rave reviews ran in every paper. Truman Capote likened Levin to Henry James. Four million copies flew off store shelves. Levin, not unlike the greedy antagonist in one of his own success-obsessed works, was granted the wildest level of literary success that he might ever had hoped for.

A year later, the success only continued with the movie, directed by Roman Polanski, a European auteur looking for his own big Hollywood break. More impeccable reviews: Roger Ebert wrote Polanski “outdoes Hitchcock”; Liz Smith in Cosmopolitan called it “sheer perfection.” Variety praised just about everyone involved: Polanski had “triumphed”; star Mia Farrow was “outstanding”; composer Krzysztof Komeda’s score was “topnotch”; and producer William Castle had “crossed an artistic Rubicon.”

Soon after, the curse began.

The first unlucky soul was Komeda. Details of his death are still scarce, but Polanski told it this way: in autumn of 1968, then 37-year-old Komeda was roughhousing at a party when he fell off a rocky escarpment and into a four-month coma—the very same affliction Levin’s witches used to kill Rosemary’s suspicious friend in the book. Komeda never regained consciousness and died in Poland the following year.

In April 1969, producer William Castle, sick with worry from the hate mail he received constantly, was suddenly stricken with severe kidney stones. While delirious in the hospital, he hallucinated scenes from the film and was said to have yelled, “Rosemary, for God’s sake, drop the knife!” Castle recovered, just barely, and never made a Hollywood hit again.