Edward Lewis, a producer who helped break the Hollywood blacklist with “Spartacus” by hiring “subversive” screenwriter Dalton Trumbo, and who later shared an Oscar nomination with his wife for producing “Missing,” about the death of an American writer in Chile, died July 27 at his home in Los Angeles. He was 99.

A daughter, Susan Lewis, confirmed the death but did not give a cause. His wife and frequent collaborator, Mildred Lewis, died April 7.

In a career that stretched back to the late 1940s, Mr. Lewis wrote occasional film scripts, produced 20 episodes of the TV anthology series “Schlitz Playhouse of Stars,” and worked with leading directors such as John Frankenheimer (“Seven Days in May”), John Huston (“The List of Adrian Messenger”) and Louis Malle (“Crackers”).

His movies earned 21 Oscar nominations, including six for “Spartacus” (1960), a swords-and-sandals epic directed by a young Stanley Kubrick and executive-produced by Kirk Douglas, who also starred as the title character, a gladiator who leads a slave revolt in ancient Rome.

Adapted from a novel by Howard Fast, which Mr. Lewis’s wife read and recommended he produce, “Spartacus” was one of the most expensive films of its time. Made on a $12 million budget — the equivalent of more than $100 million today — it featured a sprawling cast of extras and received mixed reviews upon its release, with New York Times critic Bosley Crowther dismissing it as “heroic humbug.”

But it became a fixture of late-night television and, because of Trumbo’s script, was credited with helping to bring down the Cold War-era blacklist, under which scores of purported communists and left-wing sympathizers were barred from work.

Since the late 1940s, blacklisted writers had left the country, switched fields, written under assumed names or used sympathetic producers as “fronts.” Among the most vaunted incognito scriptwriters was Trumbo, a member of the Hollywood Ten who served a brief prison sentence after being held in contempt of Congress, then wrote Oscar-winning screenplays for “Roman Holiday” and “The Brave One.”

Neither bore his name. But in January 1960, director Otto Preminger announced that his upcoming epic “Exodus” — released by United Artists, which had not signed a pledge to bar communists from its films — was written by Trumbo. Months later, Universal-International followed suit with “Spartacus,” becoming “the first major movie studio to give screen credit to a blacklisted writer,” according to a New York Times report.

While the American Legion protested the decision, the blacklist era seemed all but over when newly inaugurated President John F. Kennedy left the White House to see “Spartacus” at a nearby theater, later offering a three-word review: “It was fine.”

In interviews and a 2012 memoir, “I Am Spartacus!: Making a Film, Breaking the Blacklist,” Douglas claimed primary credit for hiring Trumbo, securing the writer’s screen credit and striking the decisive blow against anti-communist hysteria in Hollywood. To others who were involved in the movie, however, that narrative was much exaggerated.

“It was Lewis who directly commissioned Trumbo to write the script,” journalists John Meroney and Sean Coons reported in a 2012 article for the Atlantic, drawing on interviews with the families of Trumbo and Fast, who had both died, and with Mr. Lewis, who rarely spoke to the press.

Serving as a front for Trumbo, Mr. Lewis had his own name printed on the cover of the script, until “the subterfuge began to gnaw at his conscience,” according to the Atlantic. By his account, he waited until it was too late for Universal to cancel the film, then told the studio, “Take my name off the script.” He went on to negotiate a salary of more than $50,000 for Trumbo, along with 4 percent of net producer profits.

“We’ll make this thing go, Eddie,” Trumbo wrote him in a letter. “And we’ll enjoy it, too. I am most grateful to you. By way of recompense, I want the quality of my work to make you grateful to me. And then, nothing but love, gratitude, money, success, increment earned and unearned, glamour … and a torrent of good pictures.”

Indeed, Mr. Lewis produced five more scripts written by Trumbo, including “The Last Sunset” (1961) and “Lonely Are the Brave” (1962), both Westerns for Douglas’s production company. According to a 2015 biography of Trumbo, the screenwriter later wrote that Mr. Lewis “risked his name to help a man who’d lost his name.”

Edward Lewis was born in Camden, N.J., on Dec. 16, 1919. A grandfather ran a furniture business that employed his father, and his mother was a homemaker. At 16, he entered Bucknell University in Lewisburg, Pa.

Mr. Lewis apparently did not receive a bachelor’s degree before starting dental school, which he later quit to become a captain in the Army. He ran a military hospital in England during World War II before settling in Los Angeles, where he met Mildred Gerchik, the sister of an old Army buddy.

He soon persuaded her to cut off her engagement to another man, and they married around 1946, embarking on entrepreneurial ventures that included an unsuccessful pet health insurance company.

“Somehow it occurred to them to write an adaptation of a Balzac play,” Susan Lewis said, referring to the French author. “They knew some people who were in the film business, presented it, and it was made.” The film, “The Lovable Cheat” (1949), marked Mr. Lewis’s first foray into producing.

In addition to “Seven Days in May” (1964), a political thriller starring Burt Lancaster and Douglas, Mr. Lewis was producer or executive producer of eight other films with Frankenheimer, including “Seconds” (1966), “Grand Prix” (1966) and “The Iceman Cometh” (1973), based on the play by Eugene O’Neill.

Mr. Lewis and his wife, who served as the executive producer of Hal Ashby’s comedy classic “Harold and Maude,” backed the civil rights movement in Los Angeles, their daughter said. They also sought out work with a social or political edge — notably “Brothers” (1977), which they co-wrote, based on the relationship between black activists Angela Davis and George Jackson.

Their film “Missing” (1982), directed and co-written by Costa-Gavras, was based on the story of Charles Horman, an American writer and filmmaker who was living in Chile when he disappeared and was killed soon after a 1973 coup. Starring Jack Lemmon and Sissy Spacek as Horman’s father and wife, respectively, it was nominated for four Oscars but lost to “Gandhi” for best picture.

Mr. Lewis also partnered with impresario David Merrick to produce “One Flew Over the Cuckoo’s Nest,” a 1963 Broadway adaptation of the Ken Kesey novel, and shared an Emmy nomination as executive producer of “The Thorn Birds,” a 1983 hit miniseries about a family living at a sheep station in the Australian Outback.

In addition to Susan Lewis, of Manhattan, survivors include a second daughter, Joan Lewis of Los Angeles, and two grandchildren.

After co-producing “The River” (1984), about a Tennessee family trying to hold on to their farm, Mr. Lewis shifted his attention to writing projects, including novels, stories, plays and a musical, “The Good Life.” The show featured music by Randy Edelman, who wrote the score to movies including “Executive Action” (1973), a speculative account of the Kennedy assassination produced by Mr. Lewis.

“The main character is a man who’s principled, believes in things — and at 70, remains a militant, optimistic person, involved in what’s going on in the future,” Mr. Lewis told the Los Angeles Times in 1987, after the show’s premiere in Hollywood. “And you know, that’s been the theme of my own life. I’m bothered by the cynicism and negativity everywhere today. I’m an optimist; I believe there can be a good life.”