Linda Tripp, a key figure in the presidential sex scandal that nearly brought down the administration of Bill Clinton over his affair with onetime White House intern Monica S. Lewinsky, leading to the president’s impeachment in 1998, died April 8. She was 70.

The death was confirmed by her son, Ryan Tripp, who declined to discuss other details. Acquaintances said she had been hospitalized for breast cancer.

Ms. Tripp was praised as a whistleblower by some for calling out presidential misbehavior with an intern in the Oval Office, and was vilified by others as a snitch who betrayed her friendship with Lewinsky in an effort to bring down a president.

Ms. Tripp had worked as a White House secretary during the administration of President George H.W. Bush and stayed on for the first two years of the Clinton presidency, in 1993 and 1994. She later told a grand jury that she was troubled by the president’s behavior toward women.

“I had a vast font of knowledge and exposure to things that went on in this White House that I found appalling,” she testified.

At the White House, Ms. Tripp had worked in the office of White House counsel Bernard Nussbaum. She was reportedly the last person to see deputy counsel Vincent W. Foster alive before his suicide in 1993.

When Nussbaum left the White House in 1994, Ms. Tripp lobbied to stay on the job, but she was transferred to the Pentagon instead and given a $20,000 pay raise.

She began to chafe at what she considered unseemly behavior in the White House and began to explore the idea of a book about “the president’s women” with literary agent Lucianne Goldberg, who had connections with conservative writers.

In 1997, Ms. Tripp spoke to Newsweek about observing a White House volunteer, Kathleen Willey, emerging “disheveled” after an Oval Office meeting with Clinton. When asked about the encounter, Clinton’s lawyer, Robert Bennett, said, “I smell a rat. Linda Tripp is not to be believed.”

In the meantime, Lewinsky also began to work at the Pentagon. She and Ms. Tripp, 24 years apart in age, became friends and sometimes spoke to each other a dozen or more times a day, in person and on the phone. Lewinsky confided that she had a sexual relationship with Clinton and was emotionally torn over the affair.

Lewinsky has maintained that the relationship with Clinton was consensual, but Ms. Tripp saw it as her mission to protect her younger friend.

‘I didn’t just wake up one day and decide to go after a sitting president,” she told the British publication the Daily Mail in 2017, in one of her few interviews. Clinton “sees women as a sort of enormous smorgasbord. . . . He was the leader of the free world and she was an intern, a kid, who happened to be extremely emotionally young for her age.”

Ms. Tripp secretly began to record her telephone conversations, resulting in hours of intimate and sometimes graphic descriptions of Lewinsky’s relationship with Clinton. Ms. Tripp later turned over her taped recordings to independent counsel Kenneth Starr, who was already investigating investments the president and first lady Hillary Clinton had made in connection with the Whitewater real estate firm in Arkansas.

After Ms. Tripp’s evidence was introduced, Starr refocused his investigation on Clinton’s relationship with Lewinsky, convening a grand jury to determine whether the president had broken any laws.

Among other things, Ms. Tripp told Starr’s investigators about a blue dress Lewinsky had worn during an encounter with Clinton that was stained with the president’s semen. She had advised Lewinsky not to have the dress cleaned, in case she might need it as evidence.

“I just don’t want to take away your options down the road, should you need them,” she told Lewinsky during one of their conversations, later made public in the independent counsel’s write-up known as the Starr Report.

“I just, I don’t trust the people around him, and I just want you to have that for you,” Ms. Tripp added. “Put it in a baggie, put it in a Ziploc bag, and you pack it in with your treasures, for what I care.”

At her final meeting with Lewinsky in 1998, at a Northern Virginia hotel, Ms. Tripp wore a wire to record their conversation. Investigators quickly moved in and took Lewinsky away for hours of questioning.

Ms. Tripp spent eight days testifying to a grand jury convened by Starr. When Lewinsky was called to testify before the grand jury, she was asked if she had anything to add.

“I’m really sorry for everything that’s happened,” she said. “And I hate Linda Tripp.”

The president was later charged with obstruction of justice and lying under oath, regarding his affair with Lewinsky. He was impeached by the House in December 1998, went on trial in the Senate and was acquitted in February 1999.

Ms. Tripp lived in an FBI safe house for several months and was widely condemned for her role in the scandal. On “Saturday Night Live,” she was lampooned by actor John Goodman, wearing a blond wig. Donald Trump, then a New York real estate developer, called her “evil personified.”

In one of her few public statements at the time, Ms. Tripp said, “I’m an average American who found herself in a situation not of her own making.”

She was investigated by the state of Maryland for illegally taping her conversations with Lewinsky, but the case was dropped. On the final day of the Clinton presidency in 2001, Ms. Tripp was fired from her job at the Pentagon. She later won a lawsuit against the government for a violation of privacy and in 2003 reached a settlement of $595,000.

Linda Rose Carotenuto was born Nov. 24, 1949, in Whippany, N.J. Her father was a high school math and science teacher. Her German-born mother met her father during the Berlin Airlift after World War II.

During her high school years in New Jersey, Ms. Tripp’s father had an affair and left the family. Some people later said the betrayal was a formative event that scarred Ms. Tripp’s young life.

She went to secretarial school and later married Bruce M. Tripp, an Army officer, and moved with him on his military postings. She began doing clerical work at Army installations and by the 1980s was working at Fort Meade in Maryland.

In 1990, she took an assignment at the Pentagon and was soon transferred to the Bush White House. She and her husband were divorced in 1992.

After the Clinton impeachment, Ms. Tripp maintained a low profile. In her few public statements, she blasted the Clintons but maintained that her decision to expose the White House affair was “always about right and wrong, never left and right.”

She settled in Middleburg, Va., and in 2004 married architect Dieter Rausch, whom she had known since the 1960s. They operated a store that sold Christmas decorations.

Her husband and two children from her first marriage are among her survivors.

She and Lewinsky never spoke after 1998.

“I don’t know, Monica,” Ms. Tripp said during one of their conversations captured on tape. “It’s just this nagging, awful feeling I have in the back of my head. I don’t trust anybody.”