Retired car mechanic Maurice Mason believes that Ukip is "the best thing that's ever happened to politics". The 69-year-old from South Ockendon in Essex says the party has his support because it "frightened the other politicians into finally thinking 'enough is enough' with immigration".

According to new research, Mr Mason – married, a rolled-up copy of The Sun in his shorts pocket – is the archetypal Ukip voter.

Being older, white, male, married, reading a tabloid, living in one area for a long time and mixing little with other ethnicities are all predictors for being opposed to immigration, a paper published next month by the think-tank Demos will show.

In May, the Ukip leader, Nigel Farage, who is expected to announce he will stand for parliament in Thanet South next year, declared the "Ukip fox is in the Westminster hen house". His party had just gained more than 150 council seats and got 27.5 per cent of the vote in the European elections. National polls show its support has since slipped to 13 per cent, but it is expected to play an influential role in next year's general election, even if it wins only a handful of seats.

Maurice Mason (Micha Theiner)

Polling by Labour suggests Ed Miliband would become the next Prime Minister if Ukip wins at least 9 per cent of the vote, because it would take support away from the Conservatives. But others have pointed out that Ukip averaged 25 per cent of the vote in Labour areas in May and could help scupper the party's chances in key marginals.

Eric Kaufmann, professor of politics at Birkbeck College, has compared census data, polling and local election results to identify the characteristics that make Britons most likely to oppose immigration and vote for parties such as Ukip and the BNP. He found that while BNP support typically comes from areas affected by a rapid influx of migrants, Ukip is popular in predominantly white areas that have seen little demographic change.

Thurrock in south Essex is typical. The region includes the towns of Grays, Purfleet and Aveley and is home to Mr Mason and many other Ukip voters. It is relatively untouched by immigration. More than 85 per cent of its citizens are white British, down from 95 per cent in 2001, but significantly higher than the national average of 80 per cent.

Despite this, immigration and fears of a weakening national identity are issues of prime concern. On the high street in Grays, a pound shop sells enormous piles of Union flags and flip-flops printed with English flags. Even the pawn shop offering "instant cash for gold" has four St George's crosses outside.

In the latest council election, Ukip won the largest share of the vote with 39 per cent, tipping the balance of power from Labour-run to no overall control. Latest polling suggests the party a chance of unseating Jackie Doyle-Price, Thurrock's current Conservative MP. It shows Ukip leading on 36 per cent, ahead of Labour with 30 per cent and the Tories with 28 per cent.

The party has tapped into local resentment regarding immigration, despite little evidence of dramatic change. But ill-feeling often veers into overt hostility. "The colour of people has really changed a lot round here," says South Ockendon resident Leslie, 43. She adds: "I'm not racist, but when I first came here, there were one or two in my son's school; now you're looking at eight or nine in a class."

Opposition to immigration is often strongest where the fewest immigrants live, the Demos research found. More than 75 per cent of white British people are opposed to immigration in areas where fewer than 2 per cent of residents are immigrants. This compares to 60 per cent opposition in areas where 10 to 15 per cent of the population is non-British.

This, however, is not attributable to "white flight", the Demos paper argues, recording how it found that white people who are anti-immigration are no more likely to leave a diverse area than others.

Sharon, a 40-year-old barmaid at the Knight of Aveley pub near South Ockendon's Belhus estate, says: "This whole pub supports Ukip. I like their policies; they're putting us first for a change, because it does feel we're second rate in our own country at the minute. I've voted Ukip for the past few years. Before that I was never really interested in politics."

From the pub's beer garden, however, Danella Wheatley, 41, interrupts. "People support Ukip round here because they're small-minded and stupid. Everyone I know who votes for them are racist arseholes," she says. "They think it will stop anyone foreign coming in.

"A lot of people blame everything on immigration. People say 'I can't get a job because of immigrants', but a lot of people who live here haven't been out of Ockendon and they haven't got a clue."

But local people feel sidelined. Thurrock came at the bottom of a government wellbeing survey in 2012, and while unemployment is only 3.4 per cent, almost half the national average of 6.5 per cent, there is a feeling the area's identity has been eroded by the loss of its local industry. Up to 500 of the 800 workers who lost their jobs when the Coryton refinery closed were local.

Ukip head of policy of Tim Aker (Micha Theiner)

Ukip is fielding one of its favoured parliamentary candidates, Tim Aker, in Thurrock. "This is what used to be Labour central," he says in a greasy-spoon cafe next to an abandoned pub in Grays. A local Aveley boy, he is the party's head of policy and understands local people's feeling of neglect. "We've been abandoned. People have forgotten about Thurrock and they want to dump on Thurrock and people have had enough," he says.

The research evidence suggests that immigration is being blamed for the ills of areas unaffected by it. Professor Kaufmann said: "Immigration no longer factors in the voting patterns of just one sub-set. Ukip are capitalising on these various groups. They do receive support in constituencies where people see many ethnic minorities in their area.

"More interesting is the fact they are especially garnering support in communities with very low levels of diversity, experiencing the effects of immigration second hand, perhaps influenced by the media and word of mouth. People are often more concerned about levels of immigration nationally than in their own communities. They vote Ukip because of their perceptions of the issue rather than their day to day experience."