Photograph: Saul Loeb/AFP/Getty Images

It was as if “Sleepy Joe” Biden had been jolted awake and found himself in a terrifying parallel universe.

No longer was he the former senator and vice-president who once lunched weekly with Barack Obama at the White House. Instead he was the accused, standing in the dock under the hot lights on a debate stage in Miami, as a fierce and formidable prosecutor tore into his record on race.

The inquisitor was Senator Kamala Harris, a black and Asian American former prosecutor and California attorney general and who has shown a rare talent for making Jeff Sessions and other ageing white men in power squirm. Harris was surely the stand-out performer of the second in a pair of primary debates this week where the world could see a generational shift in the Democratic party happening before its eyes.

Related: 'Nobody works harder': insiders recall Kamala Harris's meteoric rise

In the most dramatic moment, Harris challenged former Biden over his recent comments about working with segregationist senators early in his career, as well as opposing government-mandated bussing – transporting students to schools within or outside their local districts to rectify racial segregation – in the 1970s. It was an exchange that illustrated a yawning gap in age and race.

“I do not believe you are a racist,” she said in a withering tone for which she is becoming famous.

“And I agree with you when you commit yourself to the importance of finding common ground. But I also believe – and it’s personal and it was hurtful to hear you talk about the reputations of two United States senators who built their reputations and career on the segregation of race in this country.”

The senator pressed on: “It was not only that, but you also worked with them to oppose bussing. There was a little girl in California who was part of the second class to integrate her public schools, and she was bussed to school every day.”

Then, the killer line: “That little girl was me.”

Story continues

There was a little girl in California who was bussed to school. That little girl was me. #DemDebate pic.twitter.com/XKm2xP1MDH — Kamala Harris (@KamalaHarris) June 28, 2019

The crowd erupted. It was the moment in every courtroom drama when the accused is skewered. It was the mic drop moment. It could possibly end up being the Biden-loses-his-third-bid-for-president moment.

Looking rattled, Biden insisted that Harris “mischaracterised my position across the board. I did not praise racists. It is not true, number one. Number two, if you want to have this campaign litigated on who supports civil rights and whether I did or not, I’m happy to do that. I was a public defender. I didn’t become a prosecutor.”

It was an attempted swipe back at Harris, whose career as a prosecutor has drawn scrutiny from progressives. Biden added: “The bottom line here is: look, everything I have done in my career – I ran because of civil rights.”

Michael Bennet, Colorado senator





Bennet raised his national profile earlier this year when the senator, typically known for his congeniality, delivered a fiery speech on the Senate floor, accusing Republican senator Ted Cruz of shedding 'crocodile tears' over the government shutdown.





Joe Biden, former vice president





Biden unsuccessfully ran for the nomination in 1988 and 2008, and his campaign is likely to be dogged by controversy after allegations from several women they were left feeling uncomfortable by their physical interactions with him. If successful, Biden would become the oldest person to be elected president in US history.





Bill de Blasio, New York mayor





Now in his second term as mayor of New York City, De Blasio is a hometown foe of Donald Trump's running on the message that there's plenty of money in the country but it's in the wrong hands. With a progressive track record but a chorus of critics in New York, can this Democrat overcome his late start and win the chance to take on Trump?





Cory Booker, New Jersey senator





Booker first made a name as the hands-on mayor of Newark. Known for his focus on criminal justice reform and impassioned speeches on immigration, he has though been criticized for ties to Wall Street.





Pete Buttigieg, South Bend mayor





Buttigieg wants to be the first openly gay millennial president. A Harvard graduate and Rhodes scholar, he became the youngest mayor of a mid-size US city at the age of 29. As a Navy Reserve lieutenant he deployed to Afghanistan.





Julián Castro, former housing and urban development secretary





Castro casts himself as an antidote to Trump and the adminstration's hardline immigration policies. The grandson of a Mexican immigrant and raised by single mother, the 44-year-old Democrat is one of the most prominent Latinos in Democratic politics.





John Delaney, former Maryland congressman





He has delivered his message of pragmatism to voters in all 99 of Iowa’s counties since he officially kicked off the race in July 2017. The multimillionaire banking entrepreneur wants to build a big-tent party that appeals to independents and moderate Republicans.





Tulsi Gabbard, Hawaii congresswoman





An Iraq war veteran who has vowed to run a campaign focused on issues of 'war and peace'. Gabbard made history as the first Samoan American and the first Hindu elected to Congress. But progressives are wary of her past conservative views on on social issues.





Kirsten Gillibrand, New York senator





Years before the #MeToo movement, the New York senator was leading efforts in Congress to combat sexual assault in the military and on college campuses. The former corporate lawyer has embraced a slate of economic ideas supported by the party’s progressive wing.





Mike Gravel, former senator of Alaska





At 88, Gravel will be the oldest candidate to be run for the nomination. However, according to his campaign, the staunch non-interventionist is not running to win, but to challenge Democratic orthodoxy on foreign policy. Will this little-known quixotic figure succeed?





Kamala Harris, California senator





Harris is one of Trump’s fiercest critics, and has built a national reputation grilling administration officials during their confirmation hearings. A former state attorney general and the daughter of immigrants from India and Jamaica, Harris believes she has the unique profile to take on Trump.





John Hickenlooper, former Governor of Colorado





Before he served two terms as governor of Colorado, the 67-year-old Democrat worked as a geologist for a petroleum company. After a lay off, he switched careers and opened a successful brewpub in Denver that helped to revitalize the city’s downtown.





Jay Inslee, Governor of Washington





Inslee is running as the “only candidate who will make defeating climate change our nation’s number one priority”. As the country experiences more powerful hurricanes, scorching wildfires and submerged coastlines, polls show public concern is growing.





Amy Klobuchar, Minnesota senator





On Election Night 2018, Klobuchar coasted to a third term as senator in a state Trump almost won. Next morning she was on every short list of potential presidential candidates. Supporters say her success with rural voters makes her a formidable candidate in the Rust Belt, while her calm demeanour provides a clear contrast with Trump.





Wayne Messam, mayor of Miramar, Florida





Facing long odds, Messam, the son of Jamaican immigrants to the US and a former receiver for the Florida State Seminoles football team, is tossing his hat in the ring anyway. The 44-year-old businessman became Miramar’s first black mayor when he was elected in 2015.





Seth Moulton, Massachusetts congressman





The Harvard educated Marine veteran arrived in Congress with a bang, after unseating a nine-term Democratic incumbent in a Massachusetts primary in 2014. Moulton has continued to make waves by calling for 'generational change' in Democratic leadership and supported an effort to block Nancy Pelosi from becoming House Speaker in 2018.





Beto O'Rourke, former Texas congressman





A one-time guitarist for an El Paso punk band called Foss, O’Rourke had kept a relatively low profile as a three-term congressman with little name recognition. He rose to national prominence during the 2018 midterms, when his bid to unseat Senator Ted Cruz garnered unprecedented grassroots support and a historic fundraising haul.





Tim Ryan, Ohio congressman





Elected to Congress in 2003 at just 29, Ryan represents the blue-collar voters Democrats hope to win back in 2020. He won national attention when he challenged Nancy Pelosi for Democratic leadership in 2016. He has continued to push for a generational change in leadership.





Bernie Sanders, Vermont senator





Sanders turned a long-shot, anti-establishment bid for the presidency into a “political revolution” that energized the party’s progressive base. His political career began nearly 40 years ago, but it wasn’t until his 2016 run that Sanders became a national figure as a new generation of Democrats – and 2020 contenders – embraced his populist economic policies.





Eric Swalwell, California congressman





Raised in Iowa and California, the 38-year-old Democrat would be among the youngest candidates in the race. Swalwell serves on the House Permanent Select Committee on Intelligence investigating Russian collusion, a position that has earned him frequent appearances on cable news shows.





Elizabeth Warren, Massachusetts senator





Her sharp criticism of Wall Street and big corporations has made Warren a favorite among progressive activists, and she will campaign on a message of a rigged economic system and income inequality.





Marianne Williamson, author





This is not the spiritual guru and a new age author’s first foray into politics: in 2014, she mounted an unsuccessful congressional bid in California. Her entry adds some star-power to the race that may attract more celebrities.





Andrew Yang, businessman





A former tech executive and entrepreneur running the longest of long shot campaigns centered on the perils of automation. His central plank is a plan to give every American adult a salary of $1,000 per month, paid for by a tax on companies that benefit the most from automation.

Lauren Gambino, Sam Morris and Martin Belam





But Harris, evidently aware that making a splash in these debates requires made-for-TV confrontation, had the accused on the ropes. “Vice-President Biden, do you agree today that you were wrong to oppose bussing in America?”

Biden retorted: “I did not oppose busing in America. What I opposed is bussing ordered by the Department of Education [rather than leaving the decision to states]. That’s what I opposed.”

Harris shot back: “There are moments in history where states fail to support the civil rights of people.”

It was a bruising exchange that exemplified the two-night debate involving 20 candidates, the speaking of Spanish and the championing of trans rights. The breakout stars were Cory Booker, Pete Buttigieg, Julián Castro, Kamala Harris and Elizabeth Warren. None is a straight white male. A changing of the guard.

Indeed, Thursday’s debate put Biden and Bernie Sanders centre-stage, two white men with a combined age of 153. On either side of them were Harris, 54, and Buttigieg, the mayor of South Bend, Indiana, who at 37 is youngest in the field and bidding to become the first openly gay president. It was Harris and Buttigieg, who was honest about his failings regarding policing and race relations, who carried the day.

Another young upstart, Eric Swalwell, made a clumsy rhetorical lunge at Biden early on, but was on to something when he said: “Joe Biden was right when he said it was time to pass the torch to a new generation of Americans 32 years ago.”

The vice-president did little to dispel that notion. Along with his grilling by Harris, he appeared rambling and uninspiring. When the candidates were asked what their first priority as president would be, he mysteriously answered beating Donald Trump. Biden seems determined to be this year’s Jeb Bush.

Sanders hit the usual notes for his base but did little to expand it. Asked about diversity, he struggled, as always, and reverted to economics. He too seemed out of touch with the America of Black Lives Matter.

Naturally, Donald Trump came in for some stick, with Sanders describing him as “a pathological liar and a racist”.

There were those in the real debate and then there was the bizarro debate. Andrew Yang, a former tech entrepreneur, and Marianne Williamson, an author, proved how hard it is for ordinary civilians to make an impression when you’re not a celebrity billionaire with a machine gun of insults.

At times there was a cacophony of voices with everyone trying to get a word in. Again, it was Harris who won that round by interjecting: “America does not want to witness a food night. They want to see how we’re going to put food on their table.”

She emerged as the victor of not only Thursday but Wednesday too. Last week, at a town hall with the Poor People’s Campaign in Washington, she seemed somewhat vague and a little pandering.

But on a debate stage, or in a committee room on Capitol Hill, she is in her element. Faced with presidential debates against 73-year-old white male Donald Trump if she is nominated as the Democratic party’s candidate, perhaps that is what matters most.

One other question lingered in the air. What did Obama make of it all?