I have a confession to make. I love not one despised style of music, but two: heavy metal, and country& western. As they scroll down my iPod, my friends weep – and retch. And it gets worse: I believe these eruptions of noise offer a political parable. Really: set aside your prejudices and your earplugs and stock up on metal and country. You will slowly see we have misunderstood two of the most politically charged, politically reviled places on earth: the Muslim world, and the Deep South. Don't turn the page over; stay with me.

I first realised that my never-quite-abandoned adolescent taste for heavy metal had a political edge in – of all places – the Jaballya refugee camp in Gaza. I was interviewing teenagers about their strangled lives and expected to hear the usual Hamasnik lines reeled back at me. But instead, they kept using words from Metallica and Slipknot to explain how they felt. "I am dying to live/Cry out/I'm trapped under ice," one of them said. They showed me their carefully-stashed CDs and T-shirts – liable to be seized by Hamas-militia at any time – and begged me to send more.

After I returned home, I discovered this was no anomaly. It turns out that the biggest market for Heavy Metal outside the US is across the Muslim world. In underground car parks in Tehran, in barns in Peshawar, in graveyards in Cairo, Muslim mosh-pits are springing up. We are constantly told that people born in Muslim countries are a homogenous sharia-seeking mass, represented by foul mullahs. But in his study, Heavy Metal Islam, Alan LeVine gives a startling statistic: in Morocco, only two forces in living memory have brought out crowds of more than 200,000: the Islamist opposition, and heavy metal bands raging against religion. To head-bang to a band called Deicide may be inane fun in London; in Iran or Egypt or Pakistan it is a strikingly brave political act.

Download the new Independent Premium app Sharing the full story, not just the headlines

At first sight, this seems bizarre. How did a style of music midwifed into the world by Ozzy Osbourne in the old English industrial town of Birmingham in the mid-1960s become an enemy of jihadism? How did a hard, brutal sound designed to mimic the factories of the Midlands become the soundtrack for the children of the Islamic revolution?

In a region controlled by senile dictatorships and fundamentalist faith, the unemployed young – who make up 65 per cent of the population – have very few windows through which to yell their rage. Metal gives it to them. Reda Zine, one of the founders of the Moroccan heavy metal scene, explains: "We play heavy metal because our lives are heavy metal." The point of the music is, he says, to rage against "the vampires of intolerance and superstition". The guitarist of Iran's hottest young metal band, Tarantist, agrees: "Metal is in our blood. It's not entertainment, it's our pain, and an antidote to the hypocrisy of religion that is injected into all of us from the moment we're born."

The police states are responding by beating heavy-metal fans with heavy metal bars. In Egypt, the dictatorship of Hosni Mubarak – funded by the US and EU – has ordered mass arrests of metalheads for "undermining the faith of Muslims", and Mahmoud Ahmadinejad is following close behind. But still millions of young Muslims and atheists defiantly sing along with Metallica: "No need to hear things that they say/Life is for my own to live my own way." Next time a Mullah claims to speak for them – or the right implies that all Muslims are represented by fanatics – remember that.

Half a world away, another style of music is equally mocked and misunderstood. Country has come to be seen as the Bush-chorus, throwing its Stetson into the air at every horror of the past eight years. It provides the theme songs for Republican presidencies; its fans are dismissed in language soaked with snobbery: they are "trailer trash", "white trash", and "rednecks" living in "the flyover states". And the psycho-anthem Toby Keith wrote after 9/11 – vowing "we'll put a boot in your ass/it's the American way" – is taken as representative of all country, all the time.

But the story of what happened to country is the story of what happened to the politics of the South. It was born at the turn of the 20th century as the tubercular music of America's dirt-poor – so it was the most populist, left-wing music America ever produced. Music historian Bill C Malone says: "You found a lot of class consciousness in older country music, and a lot of resentment against the rich and privileged." There were songs raging against the unregulated horror of the textile mills and the cotton fields. The South and Midwest voted accordingly: Kansas backed socialist candidates.

So how did Nashville become a Republican heartland? Because the Democrats stopping speaking up for the poor and the lower-middle classes – the people Hank Williams sang "had lots of luck, and it's all been bad". Why? The party became addicted to donations from the super-rich – so like the Republicans always had, they defended their donors, not their voters. There were two political parties with one economic policy. Nobody was left to talk about the economic screwing of the South. So what was left? Cultural differences. If you stopped talking about rich and poor, you started obsessing about flags and fags.

With no populists left, the old Nashville calls for taking on the rich were replaced by hippy-bashing anthems such "Okie From Muskogee". It declared: "We don't smoke marijuana in Muskogee/We don't take our trips on LSD/We like livin' right, and bein' free." (The irony is – he was stoned when he wrote it.) This trend reached its climax in 2003 when the Dixie Chicks were rail-roaded off country music stations and their albums were burned, just because they said they were ashamed to be from the same state as Bush.

But today, country is beginning to realise it was conned. The Dixie Chicks are back at the top of the charts. One of the best country songs of the past few years, by Robbie Fulks, attacks Bush for being "Countrier Than Thou": "He's got a ranch, he wears a Stetson/He's a hip-shootin' ex-oil king/But won't somebody please explain/How you can get a country sheriff/Walkin' with a frat boy's brain?" Country singers like Darryl Whorley who wrote pro-Bush anthems after 9/11 now have hits with angry anti-war songs. Even Toby Keith has been praising Barack Obama – who went on stage at the Convention to the country hit "Only in America". The South could shift, if only the Democrats will offer them country-economics.

Yes, I know my musical loves are not going to be united any time soon. I can't see Dolly Parton duetting with Slipknot, the heavy metal band who vomit on stage and then eat the vomit. But if you listen to enough metal and country, you soon learn Muslims and Southerners are not concrete clichés: they are human beings looking for a tune to sing along to. The path to a better world may just run through a Muslim mosh-pit, or a Nashville ballad for a black President.

j.hari@independent.co.uk