Image copyright Getty Images Image caption Authorities say the rise of far-right extremists is the greatest domestic threat to the US

An attack on an African-American church in South Carolina that has left nine dead is thought to be racially motivated.

The suspected gunman Dylann Roof has been pictured wearing white supremacist iconography and reportedly told his black victims: "I have to do it... You rape our women and you're taking over our country, and you have to go."

Here we look at who the white supremacists are in the United States and what defines them.

Who are they?

Like any sub-culture, they are far from a homogenous grouping but what defines them is hatred - usually directed at race and the government.

Weapons are a key part of their ideology: far-right websites dedicate entire sections to recommending what guns and other weapons to buy.

Nazi ideology is one symbol seen in nearly all far-right groups, with tattoos of swastikas common.

What do they believe?

That Caucasian/Aryan people are from a superior gene pool, and that all other minorities are inferior. There is a particularly embittered hatred towards black people linking back to slavery, but also an increasing hatred towards Hispanics as that group has grown due to migration.

Unsurprisingly, given the long-standing affinity with Nazi ideology, Jews are also hated. A commonly held belief is that the US government is controlled by Jews, denoted by the acronym ZOG, which stands for Zionist Occupied Government.

Image copyright Getty Images Image caption Some white supremacists use tattoos to distinguish themselves

How do they view Charleston attack?

Online extremist networks have erupted with news of the shooting. One thread on the major white-supremacist forum Stormfront had over 140,000 views. Users expressed a variety of opinions, but the majority used racist language and were insulting towards the dead. Pejorative and offensive racial terms were used, with some describing the gunman as a hero.

Others criticised the deaths of churchgoers and argued that the bad publicity would damage their cause. However, there was little regret for the actual loss of life.

There are also claims that the attack is a Jewish conspiracy designed to discredit white supremacist causes.

How many groups exist?

Reliable data is hard to come by, as you would expect from a mostly underground culture. The Southern Poverty Law Center (SPLC) tracks extremist groups across the US - the majority of which are white supremacist - and estimates there were 784 active groups in 2014. In South Carolina, there were 19 groups, including the Loyal White Knights of the Ku Klux Klan and the League of the South.

The white supremacist next door

'Anti-government terrorists'

Analysts and law enforcement officials point towards the rising threat of "anti-government terrorists". They are individuals on the far right who believe in extreme political conservatism and see the American government as an oppressor, but more often than not this is tied to hatred of black people and anti-Semitism.

Last year, a survey of 382 law enforcement agencies found that "74% reported anti-government extremism as one of the top three terrorist threats in their jurisdiction."

Several studies have found that home-grown extremism attacks are far more common than the more widely publicised "jihadist" attacks.

Since 9/11, right-wing extremists attacks average 337 per year compared with nine per year by Muslim Americans. Other studies using different methodology also show significantly more far-right than jihadist attacks. The University of Maryland found 65 attacks by right-wing extremists compared with 24 by Muslim extremists.

To give a sense of how diverse the threat is, the FBI has even warned that law enforcement may be infiltrated by the far right.

Lone wolf

White supremacy has increasingly splintered over the years. Now the major threat is believed to be posed by "lone wolves". This phenomenon is believed to have been encouraged by the internet, allowing loners to talk to others with similar beliefs.

Media playback is unsupported on your device Media caption "His dreams were dying": Miller's alleged actions came after years of provocative hate speech

In 2009, the Department of Homeland Security said "that white supremacist lone wolves pose the most significant domestic terrorist threat," highlighting the difficulty posed in tracking individuals working alone.

A study by the SPLC found that in the past six years, "74% of the more than 60 incidents examined were carried out, or planned, by a lone wolf, a single person operating entirely alone".

One notable recent attack was the murder of six people at a Wisconsin Sikh temple by Michael Page in 2012.

Image copyright Getty Images Image caption There are thought to be at least 5,000 Ku Klux Klan members in the US

Are they all Ku Klux Klan?

No. America's most infamous racist organisation that terrorised black Americans for much of the 20th Century is a pale shadow of what it was. The organisation never recovered from internal power struggles and heavy FBI infiltration of the 1970s. The Anti-Defamation League estimates that there are 35 Klan groups left in the US, but many of those are run by just a solitary member.

It is still estimated there are over 5,000 KKK members but they are split into small local organisations using Klan as some part of their name. The organisation's real power is symbolic. Its iconic white hood remains a recruitment badge for white supremacists.

Image copyright Facebook Image caption Dylann Roof was photographed wearing apartheid-era South Africa and Rhodesia flags

How can you spot them?

Although a disparate group of individuals, neo-Nazi ideology is common among white supremacists. Besides swastikas, the number 88 is used as a hidden Nazi symbol. H is the 8th letter in alphabet so 88 = HH = Heil Hitler.

The photograph Dylann Roof used on his Facebook profile page showed him wearing the flags of countries with a history of racial segregation. The flag of the former British colony Rhodesia, which is now known as Zimbabwe and apartheid-era South Africa. Both nations are held up as racially segregated utopias within the white supremacy movement.