After 20 years, Jack Viertel is giving up the job that everyone who loves musical theater covets: producing Encores! at City Center.

As I shouldn’t have to remind my readers, Encores! presents concert versions of musicals that, for one reason or another, have slipped away or are in danger of doing so.

The first show Viertel wanted to produce had disappeared altogether: “Juno,” an adaptation of a Sean O’Casey play that had a score by Marc Blitzstein (“The Threepenny Opera”).

“I have loved the score to ‘Juno’ since I was 14,” 70-year-old Viertel tells me. “But it’s a drama. People get killed. It’s not ‘Hello, Dolly!’ So I thought I better try to prove myself in the job before I do ‘Juno.’ ”

The first Encores! show he produced was Rodgers and Hart’s “A Connecticut Yankee,” in 2001. Viertel did it as a tribute to his parents, who took him to Broadway shows when he was a kid. They loved Ella Fitzgerald’s album “The Rodgers and Hart Song Book,” which has the definitive rendition of that musical’s “Thou Swell.”

The Encores! production was just so-so — “The show was more problematic than I thought,” Viertel says — but Christine Ebersole, singing “To Keep My Love Alive,” brought the house down.

Three months later, he did “Hair,” which, with Idina Menzel, Gavin Creel, Michael McElroy and Jesse Tyler Ferguson, was a sensation. “We sold every single ticket to that show,” he says. But he got hate mail from Encores! subscribers who objected to the nudity. “They said it was obscene and disgusting,” Viertel says. “Those letters could have been written in 1967. It must have taken a long time for them to be delivered.”

More successes followed, including “The Apple Tree,” “Finian’s Rainbow” and “Gypsy,” starring Patti LuPone — all of which transferred to Broadway.

Viertel says he never felt the pressure to give Broadway another “Chicago,” the long-running revival that started with his predecessors at Encores!

“It was always about the score,” he says. “Do we want to hear the score? And if the book is not good, how do we make it tolerable?”

He tried it with “Juno,” and while critics praised the score, one called the musical’s plot “the stuff of nightmares.”

Another show Viertel couldn’t salvage was his 2003 production of “House of Flowers,” based on Truman Capote’s book about rival brothels, with music by Harold Arlen. Pearl Bailey starred in the 1954 original, but the show was troubled out of town. By the time it got to New York, Bailey had turned it into something like a nightclub act.

“I love the score,” Viertel says. “And we tried it. But the show had just torn itself to pieces, and we could not fix it.”

Because of its prestigious reputation — 30-piece orchestras are the norm at Encores! — City Center has attracted stars. The one Viertel wanted most was Hugh Jackman for Leslie Bricusse and Anthony Newley’s 1961 show, “Stop the World — I Want To Get Off.”

“We had a meeting, and he was interested, but we couldn’t get him for nine days of rehearsals for just seven shows,” Viertel says.

One of his most acclaimed Encores! shows was 2018’s “Grand Hotel,” with a beautiful score by Robert Wright, George Forrest and Maury Yeston. Viertel had been involved in the original 1989 production as an executive of Jujamcyn Theaters, which produced the musical. It had a difficult tryout in Boston, but director Tommy Tune fixed it for Broadway, where it went on to win five Tony Awards.

Viertel says he was watching the Encores! production when he thought, “First you do shows you saw the first time. But when you start doing shows you produced the first time — well, that’s when you know it’s time to get off.”

You can hear Michael Riedel weekdays on “Len Berman and Michael Riedel in the Morning” on WOR radio 710.