Hillary Clinton clinched the Democratic presidential nomination June 6, making her the first woman in history to lead a major party. (Victoria Walker/The Washington Post)

Hillary Clinton clinched the Democratic presidential nomination June 6, making her the first woman in history to lead a major party. (Victoria Walker/The Washington Post)

Hillary Clinton has secured enough delegates to win the Democratic presidential nomination, according to the Associated Press, emerging from a long and bruising primary season to become the first woman to lead a major party in the race for the White House.

A bitter nomination battle that Clinton was once expected to win in a walk ended abruptly late Monday as she claimed exactly the number of delegates needed to secure victory in her contest against Sen. Bernie Sanders of Vermont, according the AP’s latest tally.

Clinton was widely expected — even inside her own campaign — to clinch the nomination Tuesday, when California, New Jersey and four other states are scheduled to vote. But according to the AP, Clinton continued to pick up commitments from superdelegates over the weekend, and on Monday, those gains effectively guaranteed her the nomination.

With that milestone, the former first lady, U.S. senator and secretary of state has ended more than two centuries of national history in which only men have been the standard-bearers for the major political parties. She also overcame her crushing loss to Barack Obama in the 2008 Democratic primaries, as well as a political environment this year that favored outsiders at the expense of her establishment credentials. And she became the first spouse of a former president to win the presidential nomination.

“My supporters are passionate. They are committed. They have voted for me in great numbers across the country for many reasons,” Clinton said Monday on the campaign trail in California. “But among the reasons is their belief that having a woman president would make a great statement — a historic statement — about what kind of country we are, what we stand for. It’s really emotional.”

Supporters listen to Clinton in Sacramento. (Melina Mara/The Washington Post)

Now, Clinton will turn fully to face Republican Donald Trump in the November general election, a pivot that unofficially began last week with a withering speech on foreign policy in which she shredded Trump’s qualifications and temperament. Those attacks have continued this past weekend at appearances up and down California and have been received with unprecedented enthusiasm by her supporters.

Clinton has faced an unexpectedly strong and increasingly contentious challenge from Sanders, and there is the possibility that the senator will keep battling her even now that she has effectively sewn up the nomination. Indeed, on Monday, Sanders issued this statement: “It is unfortunate that the media, in a rush to judgement, are ignoring the Democratic National Committee’s clear statement that it is wrong to count the votes of superdelegates before they actually vote at the convention this summer.”

That perspective won’t stop Clinton from celebrating the milestone Tuesday, when she had planned to claim the nomination.

Tuesday marks the exact anniversary of the day eight years ago when Clinton conceded the Democratic nomination to then-Sen. Obama. She famously promised then that a woman would someday win the White House. And she took credit for leaving “about 18 million cracks” in the “highest, hardest glass ceiling” of all during her first effort at it.

The president could endorse Clinton as soon as this week, not waiting for the Democratic convention in July, White House press secretary Josh Earnest said Monday.

The president will decide for himself when to endorse, but “we may have a better sense of where the race is headed” after Tuesday’s voting, Earnest said.

[How Bernie Sanders missed his chance to beat Hillary Clinton]

Democratic presidential front-runner Hillary Clinton speaks to Californians at Sacramento City College during a rally Sunday. (Melina Mara/The Washington Post)

An Obama endorsement would be a significant boost to Clinton as she seeks to unify Democrats after the difficult primaries. It would send a strong message to Sanders and his supporters that they should coalesce around Clinton, something Sanders has indicated he is far from ready to do.

“We’ll be talking about all of that in the next days, and I look forward to that,” Clinton said when asked what role Obama might play in her campaign. “Obviously, I’m excited about having the president’s support, because I have said throughout this campaign, I was honored to serve in the president’s Cabinet.”

Monday’s news may have stepped on Clinton’s plans to celebrate more fully on Tuesday. Her campaign manager, Robby Mook, offered this statement with the AP’s announcement: “This is an important milestone, but there are six states that are voting Tuesday, with millions of people heading to the polls, and Hillary Clinton is working to earn every vote. We look forward to Tuesday night, when Hillary Clinton will clinch not only a win in the popular vote, but also the majority of pledged delegates.”

Among other unintended consequences, campaign advisers said they fear that an early call could depress turnout in states voting Tuesday, imperiling their hopes to stave off a Sanders victory, particularly in California.

“We think it’s important to give the voters their say and not to cut off this process at this point,” Sanders spokesman Michael Briggs said during an interview on MSNBC. “I hope this is an inspiration for people all across California, in New Jersey, in North Dakota, in South Dakota, in Montana in New Mexico to go to the polls tomorrow and have your voice be heard, have your vote be counted.”

Although Clinton was widely expected to clinch the nomination before the polls close in California, she has been campaigning furiously there in recent days, in part to deny Sanders a victory on a night when she and her campaign want no doubt to remain about her nomination.

The two candidates remained locked in an exceedingly tight contest in California, with several polls within the margin of error. Clinton has been buoyed, how­ever, by a speech last week in San Diego in which she slammed Trump like never before, calling him temperamentally unfit and ill prepared to assume the presidency.

Although Clinton has increasingly appeared to be campaigning more against Trump than Sanders, the success of her speech — and its reverberations on the campaign trail in California over the weekend — may help her against Sanders on Tuesday, too.

Even Clinton’s most ardent backers say the speech revealed a new candidate, one who seemed less cautious and more willing to push boundaries.

“It was almost like Hillary Clinton was finally being herself,” said Brigette Hunley, 46, a Clinton volunteer in Solano County. “It was almost like she’s really getting into her own groove. It’s the real Hillary coming out.

“Being herself is so appealing,” Hunley added.

At times deadpan and at other times incredulous, Clinton delivered a cutting 35-minute assault on Trump on Thursday that read like a greatest hits of his most controversial comments.

It was a clear sign of how Clinton plans to defeat Trump — and overcome her own weaknesses, which include lingering questions about her judgment and trustworthiness and the fact that a majority of Americans say they don’t like her.

The business mogul has responded with a barrage of attacks on Twitter and in television interviews.

“Crooked Hillary Clinton has not held a news conference in more than 7 months,” Trump tweeted Monday. “Her record is so bad she is unable to answer tough questions!”

She took eight questions from reporters Monday.

On the campaign trail, Clinton has regularly reprised some of her favorite lines from the speech with more than a little glee.

“I didn’t make these comments up; I just repeated the ones he’s made,” Clinton said while campaigning Sunday. “I just read chapter and verse.”

Aside from California and New Jersey, Democrats are holding primaries Tuesday in New Mexico, Montana and South Dakota and caucuses in North Dakota. Republicans are holding primaries in all those states except North Dakota, but their contests are largely symbolic because Trump has secured the delegate majority he needs to claim the nomination at his party’s convention next month. Now the Democrats’ contests have less meaning, as well.

Sanders plans to take stock of his campaign at his home in Burlington, Vt., after Tuesday’s primaries.

“Let’s assess where we are after tomorrow before we make statements based on speculation,” Sanders said at a news conference in Emeryville, Calif., when asked whether he is willing to endorse Clinton in the coming weeks.

Clinton picked up more delegates in contests in Puerto Rico and the Virgin Islands over the weekend and leads the senator among both pledged delegates, those earned in voting contests, and superdelegates, the party leaders and elected officials who are free to support the candidate of their choice at the national convention.

It was superdelegates that put her over the top to gain the 2,383 needed to secure the nomination, according to the AP.

Sanders has argued that Clinton won’t have a lock because superdelegates don’t actually vote until the convention and could change their minds.

The AP said that the superdelegates for Clinton in its tally have told the news organization that they “unequivocally” support her.

Clinton’s superdelegate total has increased by 24 delegates since Sunday, according to the AP count, while Sanders’s support has scarcely budged.

The movement in Clinton’s direction underscores the vast challenge Sanders will have in flipping delegates to his side — a strategy he says he will pursue in hopes of capturing the nomination at the convention.

Speaking to reporters at a Hilton Garden Inn in a conference room overlooking the glimmering San Francisco Bay, San­ders insisted that he could still win over some superdelegates in the coming days.

“We are in private conversations,” Sanders said of his efforts to court party leaders and officials. “We’ve seen a little bit of movement,” he added, though he acknowledged that his latest super­delegate pickups number fewer than a half-dozen.

He dismissed the suggestion by a reporter that he could be a “spoiler” if he remains in the race — and he also had a tense exchange separately in which he insisted that his refusal to quit was not “sexist.”

Monday’s news — and Tuesday’s primaries — will factor heavily in the reception Sanders receives in coming weeks as he tries to make the case to superdelegates that he would be a stronger nominee than Clinton.

Obama spoke by phone Sunday with Sanders, according to two people familiar with the conversation who spoke on the condition of anonymity to discuss a private call. It was unclear whether Obama nudged Sanders to end his campaign.

Sanders is banking on a stellar performance in California, the most populous state in the nation, to bolster his argument that scores of superdelegates should switch allegiance from Clinton to him between now and the Democratic convention in late July.

It’s a strategy that most political observers consider a long shot, to say the least.

Sanders has already effectively ceded New Jersey — the second-biggest prize on Tuesday — to Clinton. Without a sweeping victory in California, he may not have much of a case left to make.

Wagner and Gearan reported from Washington. Robert Costa in Emeryville, Calif., contributed to this report.

Correction: An earlier version of this article misspelled the name of Brigette Hunley.