Mayor Pete Buttigieg, a 2020 presidential candidate, argued that a rise in white nationalism in the US is tied to economic insecurity among many blue-collar workers.

The Indiana Democrat said a new era of automation in US industries has destabilized the work-lives of many Americans, who have for generations derived much of their sense of community from their jobs.

"That void can be filled through constructive and positive things, like community involvement or family. And it can be filled by destructive things, like white identity politics," he said. But, he added, economic insecurity is no excuse for bigotry or violence.

This comes after the South Bend, Indiana mayor penned a viral letter to the Muslim community in his home town following the slaughter of 50 Muslims at two mosques in New Zealand last week.

Mayor Pete Buttigieg of South Bend, Indiana, a 2020 presidential candidate, argued that a rise in white nationalism and domestic terrorism in the US is tied to economic insecurity and the transformation in blue collar industries in the US.

"As we see dislocation and disruption in certain parts of the country, from rural areas to my home in the industrial Midwest, and in the economy, this leads to a kind of disorientation and loss of community and identity," the Indiana Democrat said in an interview with the Washington Post published Tuesday.

He went on, "That void can be filled through constructive and positive things, like community involvement or family. And it can be filled by destructive things, like white identity politics."

The 37-year-old Afghanistan War veteran argued it's "not accidental" that domestic extremism has emerged largely from economically struggling regions of the country, including from the industrial Midwest. White supremacists were responsible for the murders of 40 people in the US last year, up from 17 in 2017.

Buttigieg has long argued that a new era of automation in American business has destabilized the careers and work-lives of many Americans, who have for generations derived much of their sense of community from their jobs. That destabilization, he argues, leads people to find community in other ways — sometimes in hateful online groups where white supremacist and other radical ideologies thrive.

Read more: Pete Buttigieg wants to end the Electoral College, add more seats to the Supreme Court, and become America's youngest president

But he added that economic insecurity is no excuse for bigotry and violence.

"I don't want this to slide into the idea that some of these racist behaviors can be excused because they can be connected to economic issues," he said. "But I do think it's easier to fall into these forms of extremism when you don't know where your place is."

Buttigieg won widespread praise for a letter he wrote to the Muslim community in South Bend following the terror attack that killed 50 Muslims at two mosques in New Zealand.

In the letter, Buttigieg told Muslim Americans and immigrants that they "have an equal claim on the blessings of life" and that he and other Americans are thankful for their contributions.

This comes after Trump told reporters following the New Zealand massacre that he doesn't believe white nationalism is a rising threat in the US and around the world.

"I think it's a small group of people that have very, very serious problems, I guess," he said.

Trump has a long record of denigrating Muslims and failing to thoroughly condemn white nationalists, including when he said there were "very fine people" among neo-Nazi protesters in Charlottesville in 2017.

The Harvard graduate and former Rhodes scholar told the Post that his goal as president would be to "generate a different nationalism that does the harder task of political rhetoric, which is to make people feel bighearted and secure."