When “The West Wing” ended in 2006, Allison Janney was secretly terrified.

She worried she would never find another TV series role as powerful as the one she held in the Bartlet administration for seven seasons. She was nervous about being typecast as a specific breed of alpha-female. And she fretted that reality TV was going to take over network TV entirely, turning high-end scripted shows into endangered species.

Boy, was she wrong.

Janney, 54, is the embodiment of the extraordinary range of opportunities available to established actors in television’s ever-widening programming landscape. She took home two Emmys (Nos. 5 and 6 on her mantle) this month for her work in two very different series: the CBS comedy “Mom” and the Showtime period drama “Masters of Sex.”

Brent Humphreys for Variety

As fellow winner Julianna Margulies observed as she accepted her trophy for “The Good Wife” at the Aug. 25 Emmy Awards, “What a wonderful time for women on television.”

Janney’s wins underscore not only the expansion of the original-series marketplace but also the diversity of vibrant female characters of many ages. The notion that an actress’s career arc heads south after age 40 is laughable in an environment where Mariska Hargitay is in season 16 of “Law & Order: SVU,” Edie Falco is in season seven of “Nurse Jackie,” and Viola Davis is about to embark on “How to Get Away With Murder,” to name but a few.

“Television is a woman’s medium,” Janney said, reflecting on her two-fisted Emmy haul. “I am proud to work in TV.”

On the morning after a long night of celebrating, Janney was still effervescent. Not 24 hours after she was handed her second Emmy, the actress was game for a 90-minute photo shoot that ended with her hugging the photographer. After changing into jeans and a tank top, she perched herself cross-legged on a bed to discuss her career path.

As much as Janney loved “West Wing” — the White House drama that brought her four Emmys for playing the press secretary/chief of staff — she didn’t want to be “TV’s C.J. Cregg” for the rest of her days. When the NBC series ended, she sought to take a 180-degree turn into comedy.

“I love crazy parts — the crazier the better,” Janney said. “I love the chance to be someone who is not me on the screen. I’m so grateful that there are parts for me at my age. I hope this golden age of TV never dies.”

There were ups and downs in Janney’s immediate post-White House years. She had a deal with Chuck Lorre for a sitcom that didn’t go past the script stage at CBS — she was to have played a single dentist who falls in love with a pharmacist in her office building. She took a supporting role opposite Matthew Perry on the 2011 ABC comedy “Mr. Sunshine,” which was 13 episodes and out. And she did a pilot for NBC, “Friday Night Dinner,” with “The Office” boss Greg Daniels that didn’t get picked up.

She logged plenty of film work in that time — from “Juno” to “Hairspray” to “The Help” — and she starred in the Broadway run of tuner “9 to 5.” But she missed the live-at-home lifestyle offered by TV series work.

“I didn’t think it was going to be as hard as it was” to mount a second act in TV, Janney admitted. “I thought, ‘I’ll just find another show, and it’ll be great.’ ”

Brent Humphreys for Variety

When “Mom” finally came along, Janney’s crazy wish came true. The Warner Bros. TV sitcom from Lorre’s shop revolves around the frayed relationship between mother and daughter in dire straits, financially and otherwise, both trying to get their lives together after years of addiction and bad behavior. Janney plays Bonnie, a woman who has slept around and played around for years while mostly ignoring her daughter, played by Anna Faris.

The blend of laughs and poignant moments in “Mom” makes it a tough assignment for its stars. Lorre noted that despite Janney’s stature in the biz, she was willing to read with Faris to see if the two had the right chemistry. He called Janney a “master of her craft” who is unfailingly generous with her castmates.

“Especially early on in a show when you’re still groping around in the darkness, to have an actress like Allison who can stand and deliver no matter what you write is a gift,” Lorre said. “She is always participating in the other performances. She knows how to be part of the rhythm of the scene, even if she’s not necessarily the one with the jokes.”

Janney’s love of physical comedy — learned from years of stage work before TV and film beckoned — has informed her character, Lorre added. “There’s a wonderful recklessness to what Allison does that has enlarged the character of Bonnie beyond what we originally envisioned,” he said.

On Sony Pictures TV’s 1950s-set “Masters of Sex,” Janney plays opposite Beau Bridges as the sexually stifled wife of a college administrator who is tortured by his homosexuality. In Margaret Scully, “Masters” scribes and Janney produced one of the most nuanced portraits of a frustrated housewife ever seen on the smallscreen.

Janney has special fondness for the character, and said she took inspiration for Margaret from her own mother and the women she remembered from her childhood growing up in Cincinnati and Dayton, Ohio. “I love her quietness,” she said. “She’s more like me than any character I’ve ever played.”

“Masters of Sex” exec producer Michelle Ashford said Janney’s spark and connection with Bridges made the writers expand her part significantly.

“Once we realized that she would do and could do anything in this role, we thought we really have to go for it,” Ashford said. “She is a delight to work with — so game and funny and good-natured. She’s one of the great ones.”

For Janney, the Emmy wins amount to a big gold bonus on top of a year any actor would kill for. She’s well into production on the sophomore season of “Mom” — “Bonnie gets a job, and that’s going to change their lives a bit,” she declares — and hopeful that Margaret Scully will return in season three of “Masters.”

As Janney gathered up her Emmy-night accoutrements — the borrowed jewels, the designer gown, the beaded clutch and, of course, the winged statuettes — and prepared to head back to her three beloved dogs, she thought aloud about her plans for the rest of the afternoon.

“I’m going to go home, put these (Emmys) on the shelf and watch TV all day,” she said.