Vermont Sen. Bernie Sanders sees himself as a champion of American workers first and foremost. For years, that also made the third-term senator reflexively skeptical of increased immigration, viewing it as a potential threat to American jobs and wages.

Sanders broke with prominent Democrats to oppose a key comprehensive immigration reform bill in 2007 that would have provided a path to citizenship for millions of unauthorized immigrants living in the US. He opposed measures to increase the number of guest workers and offer green cards to citizens of countries with low levels of immigration. And he once voted for an amendment supporting a group of vigilantes that sought to take immigration enforcement into their own hands along the border (though he has since disavowed the group.)

Whether immigrants actually drive down wages for American workers, or put them out of jobs entirely, is a question that continues to divide economists. But Sanders’s public statements and voting records over his nearly three-decade career in Congress suggest he thinks they do — a belief historically shared by American labor groups but an uneasy fit with a modern Democratic Party positioning itself against President Donald Trump’s anti-immigrant rhetoric.

Sanders has long expressed the need for reforms to the immigration system overall, including a path to citizenship for the 11 million unauthorized immigrants living in the US. He consistently favored policies welcoming vulnerable immigrant populations, from DREAMers who came to the US as children without authorization to asylum seekers who experience gender-based violence.

Compared to Joe Biden, who has been forced to defend the record-high deportations that occurred while he was vice president, Sanders hasn’t faced much scrutiny over his immigration record this election cycle. His warnings against “open borders,” which he calls a “Koch brothers proposal,” drew some criticism last April, and the New York Times’s Binyamin Appelbaum pressed him on his ideas about how immigration affects wages in January, but it’s nothing like what he faced in 2016.

As Sanders runs for president for a second time, though, his views have evolved to integrate his old-school labor protectionism with a more diverse and pro-immigration Democratic Party. And he’s now embracing the most progressive immigration proposals of the field, including placing a moratorium on deportations (with some exceptions) and decriminalizing the act of crossing the border without authorization.

He still believes that immigrants who aren’t paid a living wage will drive down wages overall. But he no longer suggests immigrant workers and American-born ones are pitted against each other. Instead, he’s focusing on what the two groups have in common: Both need protection from abusive employers and big business, higher wages, better health care, and access to higher education.

When Sanders sided with conservatives on immigration

Sanders’s views on immigration were influenced by the labor movement, which for decades opposed increasing immigration, fearing that immigrants willing to work for lower wages would hurt unions’ bargaining power. The AFL-CIO had long seen immigrants as a threat to US-born workers’ wage growth. It reversed that position abruptly in 2000, supporting a path to citizenship for unauthorized immigrants — a move that later helped coalesce Democratic support around the issue.

Sanders has supported legalizing the US’s unauthorized immigrant population since at least 2007, but he also repeatedly expressed concern that increasing immigration, particularly among guest workers, hurts US workers.

“It does not make a lot of sense to me to bring hundreds of thousands of those workers into this country to work for minimum wage and compete with Americans kids,” Sanders said in 2013.

That’s earned him praise in conservative circles: Both Roy Beck, the president of NumbersUSA, which advocates for dramatically restricting immigration, and Republican Rep. Steve King of Iowa told Time in 2016 that they believe Sanders shares their priority of protecting American workers over immigrants.

“I think in his gut he believes his obligation as president would be to the workers of America, not to the workers of the world,” Beck said.

Sanders has never had to answer to a large immigrant constituency. While noncitizens and naturalized citizens make up about 13 percent of the population in his hometown of Burlington — on par with the nationwide share of the population that is foreign-born — they only account for about 4.5 percent of Vermont’s population overall.

Nor was he alone in being an immigration skeptic on the left during the 1990s and 2000s, when securing the border was a bipartisan issue. But on a few key immigration votes, he broke with the majority of Democrats. (All of Sanders’s votes were, essentially, symbolic: None of the votes ended up being close.)

Sanders backed an amendment in 2005 to dismantle the diversity visa lottery, under which 50,000 annually green cards are granted to citizens of countries with low levels of immigration. The program has since become a target of Trump’s ire.

In 2006, he supported the Minutemen, a civilian militia that patrolled the southern border with the aim of preventing unauthorized immigrants from crossing, voting for an amendment to bar American officials from sharing information about the group’s activities with the Mexican government after Republicans took to the House floor claiming that the vigilantes were filling a “void which the government was unable to fill.” (In 2015, Sanders’s presidential campaign dismissed it as a meaningless “nuisance amendment.”)

But perhaps his most significant break with Democrats on immigration came when he was a freshman senator in 2007. Sanders voted against President George W. Bush’s comprehensive immigration reform bill — a decision that drew criticism from Hillary Clinton during the 2016 presidential election.

The bill would have opened a pathway to citizenship for the millions of unauthorized immigrants living in the US while investing in border security. Sanders has said that he voted against the bill, which failed after the Senate voted 53-46 to table it, because of the lack of labor protections in the bill’s guest worker provisions.

“Our border is very porous,” he said during a press event at the time. “And I think at a time when the middle class is shrinking, the last thing we need is to bring over in a period of years, millions of people into this country who are prepared to lower wages for American workers.”

Sanders was by no means the only Democrat to oppose the bill: At the time, the question of whether to legalize the population of unauthorized immigrants living in the US divided the Democratic party. But a number of prominent Democrats, including Barack Obama and Clinton, did support the legislation.

A spokesperson for Sanders’s campaign noted that a number of prominent immigrant and Latino advocacy groups — including the League of United Latin American Citizens (LULAC), the American Immigration Lawyers Association, and the Hispanic Federation — as well as labor organizers such as the AFL-CIO opposed the 2007 bill for the same reasons. (The bill ultimately failed because of a revolt on the right, not the left, as Republicans in the Senate deserted the measure in droves.)

The Coalition for Comprehensive Immigration Reform, which represented 43 immigrant rights organizations — including the National Immigration Law Center and the National Council of La Raza, now known as UnidosUS — did back the bill.

Clarissa Martínez-de-Castro, who oversaw that coalition at the time, said that while the bill wasn’t perfect, there was an understanding that the costs of failing to legalize the population of unauthorized immigrants in the US were too great. US workers feel those costs, too: In a system where unauthorized immigrants aren’t encouraged to come forward, bad-apple employers can get away with paying all their employees pittance wages.

The coalition was consequently focused on keeping the legislation alive in the Senate so that it could be amended in the House — an effort that Sanders helped stymie.

“We needed the legislation to move forward in the Senate with the hope of improving it,” Martínez-de-Castro said. “Many advocates knew the consequences of inaction. We have been living with those until this day.”

Sanders continued to oppose efforts to expand guest worker programs for years after the 2007 comprehensive immigration reform bill failed.

Just months later, he introduced legislation that would have given the federal government more tools to crack down on employers who abuse temporary immigrant worker programs and established protections for both those workers and US workers competing for the same jobs.

He supported an amendment from Sen. Chuck Grassley (R-IA) that would have prohibited banks receiving federal bailout funds after the 2008 financial crisis from hiring guest workers, arguing that they would otherwise have leeway to replace Americans with cheaper foreign labor.

He also opposed provisions in the 2013 comprehensive immigration reform package that would have substantially increased the number of visas available for temporary guest workers, suggesting that it would primarily benefit large corporations at the expense of unemployed Americans and the middle class. By that time, Democrats were unified in calling for a path to citizenship for unauthorized immigrants, and so Sanders eventually voted for the bill after a $1.5 billion training program for younger workers was included.

As late as July 2015, as he was making his first presidential bid, he reiterated the idea that immigration hurts American workers, even while proposing an immigration plan that was one of the most progressive of the Democratic field: He had, for example, promised to use executive action to shield unauthorized immigrants who have been living in the US for at least five years from deportation, whereas Clinton would have sought legislation to do so.

“There is a reason why Wall Street and all of corporate America likes immigration reform, and it is not, in my view, that they’re staying up nights worrying about undocumented workers in this country,” he said during a Q&A with the US Hispanic Chamber of Commerce. “What I think they are interested in is seeing a process by which we can bring low-wage labor of all levels into this country to depress wages for Americans, and I strongly disagree with that.”

How Sanders has supported vulnerable immigrants

While Sanders has been wary of opening the door to more immigrant workers, he has consistently supported protecting vulnerable immigrant populations since he was a first-term member of Congress.

He seems to have drawn a distinction between immigrants who are coming to the US to seek economic opportunity and those who are deserving of humanitarian protections such as asylum. He appeared to believe that the US has an obligation not only to protect its own workers from economic migrants but also to offer refuge to those who need it.

Sanders supported limits on the detention of immigrant families long before the issue attracted national scrutiny under the Trump administration. In 1991, he co-sponsored a bill that would have prevented parents and their young children from being detained for more than 24 hours before their deportation. Currently, children can be kept in detention for as long as 20 days.

In 1996, he broke with a majority of Democrats in Congress by voting against what is now recognized as one of the most punitive immigration laws on the books, the Illegal Immigration Reform and Immigrant Responsibility Act. The Clinton-era law was touted as centrist at the time but is largely responsible for the federal government’s massive detention and deportation engine as it exists today.

He has also supported bills that would have made victims of gender-based violence eligible for asylum and other protections, allowed LGBTQ individuals to sponsor their partners for immigration benefits before the recognition of same-sex marriage, and offered government-appointed legal counsel to immigrant children facing deportation.

Sanders backed every version of the DREAM Act — a bill that would have offered a path to citizenship for young unauthorized immigrants who came to the US as children — since 2007. All the various iterations of the bill have failed to pass, but then-President Obama offered protections to those immigrants via executive order instead, creating the Deferred Action for Childhood Arrivals (DACA) program. And after Obama came under fire for doing so, Sanders came to his defense.

He has also repeatedly voted against legislation that would have expanded immigration enforcement — even before he focused on reducing the record-high deportations that occurred during the Obama administration in his 2016 campaign.

He voted against legislation in 2005 that would have, among other provisions strengthening immigration enforcement, criminalized all violations of federal immigration law, including being present in the US without authorization. It would have meant that the nearly 11 million unauthorized immigrants living in the US could have been prosecuted.

Sanders again broke with prominent Democrats — including then-Sens. Obama and Clinton — in voting against the Secure Fence Act in 2006, which passed with overwhelming bipartisan support and ordered the construction of 700 miles’ worth of fencing along parts of the US-Mexico border. That same year, he also voted against a bill that would have offered local law enforcement the ability to “investigate, identify, arrest, detail, or transfer to federal custody” all unauthorized immigrants.

How Sanders’s views on immigration have evolved

Sanders no longer talks about immigrants and American workers as competition, but instead as two groups facing the same challenges. That evolution has been gradual over the years: Sanders was advocating for migrant workers as early as 2008, when he visited them in the tomato fields of southern Florida and invited them to testify at a Senate committee hearing regarding abusive labor practices.

In 2020, Sanders has appeared to reach a middle ground on his views of worker rights and immigration policy: He is pairing protections for both immigrant and American workers with some of the most progressive immigration proposals of the Democratic field.

Though he faced criticism last April after he eschewed the idea of “open borders,” he has been trying to shift the conversation toward the harms of exploiting immigrant workers.

“Right now, we have people who are being exploited,” he told the New York Times in a recent interview. “If you’re undocumented, and you’re being paid five bucks an hour, why am I going to pay her $12 an hour? And that’s why the labor law that I am proposing will make sure you pay that worker $15 an hour, as a matter of fact.”

The prominent immigrant rights group Make the Road Action and the Latino mobilization group Mijente later endorsed Sanders, likely giving him an edge in the early caucus state of Nevada — where Latinos make up almost a third of the electorate — and in Latino communities across the nation.

Immigration ranks highly in terms of importance to Latinos, but it historically hasn’t been their top priority overall, ranking behind health care and the economy. That’s held true this election cycle: Only 11 percent of Latino voters said that protecting immigrant rights is the most important issue facing the community, according to a February 18 Univision poll.

But it’s still notable that, despite his record on immigration questions, Sanders leads the Democratic field among Latino voters 30 percent nationwide and has swept the Latino vote in all the early primary contests so far.

Daniel Altschuler, managing director of Make the Road Action, said the organization has been impressed by Sanders’s willingness to listen and learn from the grassroots advocacy community in putting together an immigration platform that reflects their priorities, including placing a moratorium on deportations and dismantling the immigration enforcement agencies.

While Sanders previously insinuated that he would pause all deportations, his campaign manager Faiz Shakir clarified recently at a forum moderated by BuzzFeed News’s Hamed Aleaziz that there would be some exceptions. He said the moratorium wouldn’t apply to immigrants who are “violent criminals,” and those serving time in prison could also be deported after being evaluated “on a case by case basis,” but “99% of the people living here” would be shielded from deportation. For some immigrant advocacy groups, though, even those narrow exceptions would open the door to too many deportations.

“This is not what we mean by a moratorium, but we expect to have to push [for] a Sanders presidency,” Tania Unzueta, a spokesperson for Mijente, told BuzzFeed.

Sanders’s plan also acknowledges that unauthorized immigrants are particularly vulnerable to abuses at the hands of employers because they might fear retaliation that could put them at risk of deportation. He consequently suggests redirecting funding from enforcing immigration laws against workers to holding their employers accountable for labor law violations. (The plan does not mention whether that will include preventing employers from hiring unauthorized workers in the first place.)

He suggests offering immigrant workers whistleblower protections if they speak up about workplace abuses and improving labor standards for farmworkers, domestic workers, gig economy workers, and those employed in other underregulated industries. He would also allow them to participate in Medicare-for-all and College for All, his bill to make public colleges and universities tuition- and debt-free.

That message has taken on new urgency in light of Trump administration immigration raids targeting unauthorized workers over the past year. In one raid in August, 680 workers were arrested at seven Mississippi poultry plants.

Altogether, the plan represents the culmination of an evolution of Sanders’s views on immigration in a way that is in line with what the American public has wanted for years, Martínez-de-Castro said.

“Bernie Sanders has been a champion for working-class people throughout his career. What is heartening is to see that commitment to the rights and needs of workers married with a deeper understanding of the priorities of the immigrant community writ large,” Altschuler said. “Our movement sees him as a partner.”