WASHINGTON — There was a brief moment in Nancy Pelosi’s life when she worried she had too much power. She had so many titles in the California Democratic Party, including chairwoman, that she told Lindy Boggs, a Louisiana congresswoman, that she was thinking of giving some up.
That was in 1984, and Ms. Boggs “said, ‘Darlin’, no man would ever think that. Don’t you give anything up,’” Ms. Pelosi said in a recent interview, leaning forward as she mimicked Ms. Boggs’s Southern accent. “And then she said, ‘Know thy power.’”
More than three decades later, Ms. Pelosi is all but assured on Thursday of reclaiming her former title as speaker of the House, the first lawmaker in more than half a century to hold the office twice. With the gavel in hand, she will cement her status as the highest-ranking and most powerful elected woman in American political history.
The story of her rise, from the well-mannered daughter of a Baltimore mayor to a savvy legislator and prolific fund-raiser who is as much feared within her caucus as she is admired, is, in some ways, the story of the women’s movement itself. It is also a comeback story; after losing the speakership eight years ago, she will now usher in a new era of divided government in Washington.
And in the era of #MeToo, Ms. Pelosi, a mother of five and grandmother of nine, will be the public face of the opposition to a president who won the White House after disparaging women, and paying hush money to a Playboy model and a pornographic film actress who said they had extramarital affairs with him.
But Ms. Pelosi, 78, long a target of Republicans who have demonized her as a San Francisco liberal, is also coming to the speakership with self-imposed constraints. To quell an uprising among Democrats who wanted a younger generation of leaders, she has agreed to limit her term to four years. Some say that could weaken her — a notion she dismissed.
“I’m used to, shall we say, enthusiasms from all elements of the party — I can roll with that,” she said.
Republicans do not underestimate her. “She is a skilled adversary and a master at keeping all Democrats in line,” said Representative Mark Meadows of North Carolina, the chairman of the conservative House Freedom Caucus.
Ms. Pelosi knows that this speakership will be defined by how she handles President Trump. The last time she was speaker, from 2007 to 2011, legislative accomplishments made her reputation. She muscled through bills that bailed out Wall Street and helped arrest an economic free-fall, allowed gays to serve in the military, overhauled the nation’s banking laws and expanded access to health care for an estimated 17 million people. Many say passage of the Affordable Care Act is her signature achievement.
But divided government, an unpopular president and wide-ranging, possibly criminal investigations into Mr. Trump, his presidential campaign and his businesses have changed her role drastically.
“This is legacy-building time,” said Jennifer Lawless, an expert on women in politics at the University of Virginia. “If she can be the person who is remembered for holding Trump accountable, or not letting him put forward facts that are not facts, if she can be the one who just calmly sits there and hold his feet to the fire, in a lot of ways, that’s just as important as anything else she does.”
On a recent Saturday morning, Ms. Pelosi ducked into a closet in her office and retrieved a T-shirt that a colleague had given her, bearing the quote that she used to smack down Mr. Trump during a televised Oval Office meeting on his border wall: “Don’t characterize the strength that I bring.”
“You know, it’s really sad. Nothing he said was true — nothing,” Ms. Pelosi said of that December meeting.
Her power stride out of the White House that day, in dark sunglasses and an orange coat, turned Ms. Pelosi into a fashion trendsetter; ever mindful of the messages she sends, she frets that she needs to retire the coat: “If I show up with that coat, doesn’t it look a little like — hey, look at me?”
Ms. Pelosi has long governed with a touch of gender-consciousness. When she became speaker the first time, she surrounded herself with her grandchildren and the children of other lawmakers on the podium inside the House chamber. A woman was in charge.
This time Ms. Pelosi seems to be casting off maternal imagery. “I put on a suit of armor, eat nails for breakfast,” CNN quoted her as saying.
One good friend, former Senator Barbara Boxer of California, said Ms. Pelosi seemed “very liberated” after surviving the challenge to her speakership, and coming off the meeting with Mr. Trump. “They tried to kick her down, and I don’t think she ever got down,” Ms. Boxer said.
A generation of young feminists is taking notice.
“She’s unapologetic about her ambition, she’s insulting Trump’s manhood and storming out of the White House in orange coat and sunglasses,” said Amanda Litman, 28, and a founder of Run for Something, which recruits and supports young liberal candidates. “It’s very authentically her in a way that I’m not sure she was able to do in past decades.”
Most accounts of Ms. Pelosi’s rise begin with her father, Thomas D’Alesandro Jr., an old machine politician who doled out favors from their living room in Baltimore’s Little Italy. But her mother, Annunciata, was an equally powerful role model.
“Big Nancy,” as she was known, was a strategist, an organizer of Democratic women and the keeper of what the family called “the favor file.” From her, Ms. Pelosi learned the power of social networking and the personal approach to give and take in negotiations.
“Nancy knows how to listen; she learned that from her mother,” said former Senator Barbara A. Mikulski, a Baltimore native who was a few years ahead of Ms. Pelosi in their all-girls Catholic high school.
Young Nancy D’Alesandro had dreams of becoming a lawyer, but by the time the women’s liberation movement was in full swing, she was married to her husband, Paul, and raising children.
“We missed the burning bra,” said Rita Meyer, a college roommate and close friend. “We missed the marijuana.”
Even when she was pushing strollers, Ms. Pelosi said, she was active in Democratic politics and pushing her own children to get involved. With her husband growing ever more successful in business, they opened their large home on one of San Francisco’s most exclusive streets for Democratic events.
A turning point for Ms. Pelosi came in 1976, when she got behind the presidential campaign of Gov. Jerry Brown of California. She persuaded him to compete in the Maryland Democratic primary, drawing on her ties (her brother Tommy had also been Baltimore mayor) to help engineer his victory, a setback for Jimmy Carter.
“I had no direct knowledge of anybody or anything in Maryland,” Mr. Brown, wrapping up his second stint as governor, said in an interview. “It was her idea. Just to think of that is a bold move.”
Ms. Pelosi then was chairwoman of the California Democratic Party and helped organize its 1984 convention. Then, in 1987, Sala Burton, the incumbent congresswoman from San Francisco who was dying of cancer, summoned Ms. Pelosi to her bedside and asked her to run to fill her seat.
There were 23 women in the House — 12 Democrats and 11 Republicans — when Ms. Pelosi arrived. Ms. Boxer, who was then serving in the House, recalled an event where a colleague — she could not recall who — introduced his fellow members.
“He goes through everybody, and then he gets to us and he said, ‘And then there’s Nancy and Barbara,’” Ms. Boxer recalled. “She and I never forgot it.”
Ms. Pelosi carved out a niche as an advocate for human rights, particularly in China, and for AIDS patients, a significant part of her San Francisco constituency. She sought, and eventually landed, a seat on the powerful Appropriations Committee and a national security post on the Intelligence Committee.
She was forceful about her ideas, said George Miller, a retired congressman and close friend, adding, “I don’t know that leadership was all that excited” to hear them. At a Democratic retreat after the party lost the majority in 1994, Ms. Pelosi planned a presentation on how Democrats in California picked up seats. Almost nobody came.
“She said, ‘These boys just don’t know how to win,’” Mr. Miller remembered.
In 2001, Ms. Pelosi was elected Democratic whip, beating her longtime rival, Representative Steny D. Hoyer of Maryland, to become the first woman to hold that post. The next year she was elected Democratic leader, the first woman to lead a party in Congress. At her swearing in, she distributed buttons that read, “We’ve waited more than 200 years for this day.”
Ms. Pelosi was swept into power as speaker in 2007 on a wave of revulsion over President George W. Bush and the war in Iraq. But she proved that she could work with Mr. Bush when needed; as the country faced economic collapse in 2008, she delivered the necessary votes to pass a Wall Street bailout plan — after Mr. Bush’s Treasury secretary, Henry M. Paulson Jr., got down on one knee and begged. (“I didn’t know you were Catholic,” she wryly said to him.)
She was relentless in gathering votes, even when it put her members in jeopardy. If her own pressure campaigns and horse-trading did not work, she would call in outsiders. Henry A. Waxman, a former California congressman, recalled Ms. Pelosi’s effort to win over a nervous young member, Zack Space, on a climate change bill that had almost no prospects in the Senate. Mr. Space had Greek roots.
“She had a woman, a leader in the national Greek community, talk to him,” Mr. Waxman said, “and then this woman came and sat in the front row while the vote was taking place.” Mr. Space got the message, voted yes, then lost his re-election.
But she is most remembered for passage of the Affordable Care Act, without a single Republican vote. Norman J. Ornstein, who has studied Congress for decades at the American Enterprise Institute, called it “as masterful a piece of legislating as I have ever seen.”
It may have been matched only by her remarkable talent for raising money. Ms. Pelosi has raised $ 728.3 million for Democrats since 2002, her office said.
Now, after an election that ushered a record number of women into Congress, Ms. Pelosi is determined not to let another history-making moment pass. She is marking her return to power with a string of events, including a women’s tea, a dinner at the Italian Embassy featuring the singer Tony Bennett and a town hall-style meeting, televised on MSNBC.
Asked if she considers herself Mr. Trump’s equal, she replied, “The Constitution does.” She frowned at the memory of a dinner at the White House last year when men talked over her, and she asked, “Doesn’t anybody listen to a woman in the room?”
“Hopefully that will become a thing of the past now that we have so many women in Congress — and with the gavel,” Ms. Pelosi said. “The gavel makes a big difference.”