Hundreds of thousands of people crowded downtown Los Angeles streets on a sunny January morning to hear Hollywood stars like Constance Wu, Natalie Portman, Eva Longoria and Viola Davis issue a call to action: resist Trump.

Movements like the Women’s March and Time’s Up energized the electorate and helped send a record number of women to Congress in the midterm election. Ninety-five women have won their House races as of Wednesday, up from the current 84.

The midterm election saw a number milestones, from the first Muslim women elected to Congress, Rashida Tlaib in Michigan and Ilhan Omar in Minnesota, to voters in Massachusetts sending the first woman of color to Congress, Ayanna Pressley. Democrats Sharice Davids and Deb Haaland became the first Native American women elected to Congress.

Several prominent women also were defeated, including Sen. Claire McCaskill, who lost to Josh Hawley in Missouri, Sen. Heidi Heitkamp, who failed to win re-election in North Dakota, and Amy McGrath, a former Marine fighter pilot who fell short in her House bid in Kentucky.

Political pundits trace the historic outcome at the ballot box to an unprecedented level of grassroots activism, which tapped into anger over Donald J. Trump’s remarks about grabbing women’s genitals without their consent, and outrage over reports of sexual misconduct by other powerful men, including former Hollywood producer Harvey Weinstein.

“Without question there is a direct relationship between the election of Donald Trump, his rhetoric, the response the day after the inauguration, the organization of the #MeToo movement and the Time’s Up movement,” said political analyst and USC professor Sherry Bebitch Jeffe.

Jeffe said female candidates or their supporters, when interviewed, frequently say they have been politicized either by the sexual harassment revelations, or by Trump’s rhetoric. A record number of women — as many as 575 women declared their intention to run for the House, the Senate or governor, according to Politico — sought public office this year.

“We believe that there’s an awakening that’s happening right now,” said Katie McGrath, Co-CEO at Bad Robot Productions and Time’s Up founding member. “And 100 (women elected to Congress), though it is historic, obviously it’s not a satisfying outcome. We would like to be at 50 to 51%. This is the first step in that journey.”

Women began mobilizing opposition to Trump immediately after his election, staging the largest public demonstration in the nation’s history the day after his inauguration on Jan. 20, 2017. An infrastructure to promote female candidates began to rise up, to match the public fervor. Nascent groups, like Time’s Up and the Women’s March, were able to work alongside established organizations like Planned Parenthood and NARAL Pro-Choice America, which have top-notch field organizations.

“They had structures that an energized female electorate could plug into,” said McGrath.

EMILY’s List, a national political action committee that works to elect pro-choice female Democrats, pumped more than $5 million into political campaigns, helping fuel the successful bid of Democratic Rep. Jacky Rosen, who unseated GOP Sen. Dean Heller to represent Nevada in the Senate.

“Two things are going on,” Boston University professor Virginia Sapio told Vox. “More Democratic women are energized because of the anti-woman stance of the current administration, and there is a growth of organizations devoted to recruiting and training Democratic women candidates.”

Hollywood performers, who are typically shy about engaging in political activism for fear of alienating audiences, stepped forward. Grey’s Anatomy and Scandal creator Shonda Rhimes delivered the keynote speech at a voter registration event at USC’s Galen Center in September that drew 10,000 people. Black-ish star Tracee Ellis Ross lent her support to the Swing Left campaign, a national grassroots network of over 350,000 volunteers supporting Democratic candidates.

A new coalition of celebrities and activists, including actress Alyssa Milano and Parkland High School student advocate David Hogg, launched the NoRA initiative to take on the National Rifle Association and the politicians who accept money from the powerful gun lobby.

On election night, many in Hollywood who had a hand in electoral efforts were celebrating.