Democrat Randy Villegas has defeated Republican incumbent David Valadao in the race for California's 22nd congressional district, prevailing in one of the state's most closely watched contests and securing another victory for the Democratic Party's progressive left in the Central Valley.

Villegas, an educator who grew up in the region as the son of Mexican immigrants, ran a campaign that drew support from figures such as Senator Bernie Sanders while hammering the rising cost of living, healthcare cuts and sweeping immigration raids.

Speaking to supporters in the city of Bakersfield on Tuesday evening, Villegas credited his parents' sacrifices as the reason he believes in the United States and called the outcome a "historic victory for the Central Valley". "And let me tell you, that victory is not because of me. It is because of us," he added.

The district's result mirrors a broader national pattern on election night, as voters angry about surging prices, driven partly by the Trump administration's decision to launch a war on Iran, and about overreach in areas such as ICE raids moved to punish the president and his party. Polls had shown for months that the president was deeply unpopular, a trend closely tied to collapsing confidence in his handling of the economy and the cost of living, the same issues that had helped return him to the White House in 2024. Despite his image as a relative moderate with strong local ties, Valadao did not escape that trend on Tuesday night.

The race also highlighted a sharp reversal among Latino voters. After Trump's 2024 win, much was made of Republican inroads with that community, but less than two years later those gains have entirely evaporated, with Latino voters across the country swinging heavily back to the Democrats over aggressive and often indiscriminate immigration enforcement and rising prices. "We have people who said that they regret having voted for him [Trump], because he has not done what he promised," a member of the United Farm Workers labour union who knocked on doors in Latino communities for Villegas told Al Jazeera on Monday.

Residents and officials in the Central Valley said ICE raids sent shockwaves through immigrant and Latino communities, with arrests of farmworkers and family members cutting against the administration's claims that it was targeting criminals. Villegas condemned the raids and tied them to Valadao's support for a massive increase in the budget for ICE, one of the agencies at the centre of the mass deportation campaign. A recent Pew Research Center survey found that 56 percent of US voters now view ICE unfavourably, making it one of the least popular agencies in the federal government.

Before taking on Valadao, Villegas had to survive a hard-fought primary against California State Assembly member Jasmeet Bains, a candidate aligned with the party's establishment wing who warned that his progressive positions would prove too far left for the traditionally conservative region. His populist message instead appeared to resonate in a race dominated by concerns about the cost of living and access to healthcare, at a time when many voters feel politics and the economy are skewed toward the wealthy and well-connected.

Backed by endorsements from Sanders and Representative Alexandria Ocasio-Cortez, Villegas energised the party's base, including organised labour members who pounded the pavement to turn out the vote. "We beat the Democratic establishment. We beat the Republican establishment. We beat corporate PAC money. We beat AIPAC!" he told supporters on Tuesday night. He now joins the list of elected officials seeking to prove that progressives can win tough races outside traditional strongholds.

Manpreet Kaur, the progressive vice mayor of Bakersfield and an early Villegas supporter, said the race showed that the Central Valley "cannot be counted out of following the really urgent change that we need in every corner of our country," adding: "And the Central Valley is included in that."