The American tourist sipping a frosty beer by an oceanside shack had been in Goa just a few hours before a man sidled up to him and asked whether he wanted to buy drugs.

“I heard the waves, my toes dug into the sand, and my weekend holiday had just begun,” said Pablo Rosa, 48, from Texas. “Even before I got my feet wet in the water, I was offered drugs. That’s how easy and open it is here.”

Over the past three decades, the tiny western Indian state of Goa has become a popular beach destination for Indians and foreigners alike, offering a mix of sun, sand, dance music festivals, ayurvedic-healing resorts and businesses bearing names such as Karmic Cafe, Buddha Tattoo and Nirvana Bar.

But the sun-seekers’ haven is rapidly acquiring a darker reputation — as a hub for international drug trafficking and Ecstasy-chasing tourists.

A few weeks ago, the shadowy subculture of the area dubbed India’s “cocaine coast” by the news media was exposed when violence spilled onto the streets: After a Nigerian man was killed in a turf war between drug gangs, more than 150 outraged Nigerians dragged his body from a police hearse, attacked the officers and blocked a national highway for hours.

The protest sparked a backlash against Nigerians among local residents, part of a growing uneasiness about the Africans’ presence here, which some observers say reflects a wider trend of racism in India. Banners bearing slogans such as “Say No to Nigerians, Say No to Drugs” hung in the streets. Many Goans said they will not rent rooms, motorcycles or scooters to Nigerians. One Goa politician said Nigerians are like cancer; another likened them to wild animals.

“Soon every Goa street will be ruled by drug gangs and their political cahoots,” read the headline of a column in a newspaper called the Goan.

“People in Goa are reacting in a mixed and confused manner to all the changes tourism has brought,” said Frederick Noronha, who runs a nonfiction publishing house called Goa 1556.

The tension was exacerbated when the government ordered the arrest and deportation of all Nigerians without valid documents, triggering a diplomatic furor. Thirty-four of the 52 Nigerians arrested in the highway protest lacked valid papers, according to a state immigration official.

“Indian people do not like us, some clubs say they do not want to serve us, and now these calls for boycotts against us,” said Joe Prince, a 31-year-old Nigerian businessman who said he had not stepped out of his home in a village in Goa since the killing. “We have silently suffered insults for years, but now it is out in public. Indians look at us and think ‘black’ and ‘drug peddlers.’ ”

The turmoil has shaken Goa’s easygoing cosmopolitan culture, which has drawn hippies from abroad since the 1960s. As tourist season gets underway, many local residents are debating whether the region has paid too high a price for the tourism boom.

“What we are seeing now is what we have known for years. The situation did not develop overnight,” said Dattesh Parulekar, an assistant professor of international relations at Goa University. “So many foreigners have come here and set up local businesses, beach shacks and hotels, run the drug trade and bought up huge tracts of land. The local people have watched helplessly as their area changed, but they are also unable to extricate themselves from the profit that tourism brings.”

For many in Goa, a former Portuguese colony, the gang-fighting comes as a warning to clean up the tourist trade, which attracted more than 2.7 million international and domestic visitors last year. Worried residents say some of them are the wrong kind.

“We know what goes on in the name of tourism here — drugs and flesh trade,” said Vasudev Arlekar, president of the local taxi-owners association. “India’s tourism slogan is ‘Guest is God.’ But how can we worship guests who are doing all this nonsense?”

Goa’s narcotics trade is worth about $950 million a year, police officials say, and includes marijuana, heroin, cocaine, meth, ecstasy and synthetic drugs.

For a long period, drug trafficking in Goa was controlled by separate gangs run by Britons, Israelis, Russians and Indians, who maintained an uneasy peace by operating on different beaches, police said. But in the past four years, Nigerians have infiltrated the trade, with scant regard for others’ established turfs.

“The Nigerians have entered in large numbers and will sell to anybody and everybody — on the beach, outside clubs and on the streets,” said Kartik Kashyap, superintendent of the police anti-
narcotics unit. “That is why the public perception about them is negative.”

Police said 189 Nigerians have been arrested in Goa since 2010, on charges including lack of valid travel documents and involvement in drug trafficking. About 40 percent of the foreigners arrested on drug-trafficking charges in the state since 2009 are Nigerians.

Just two weeks before the killing of the Ni­ger­ian man, Goa’s police busted two major drug rackets, seizing more than four kilograms of amphetamine from a British drug-dealer and more than 450 grams of cocaine from two Nigerians.

Police say they have recovered more drugs from raids this year than in the past four years combined.

The drug gang wars are “a manifestation of the rot that has set in,” Kashyap said. “These activities cannot be divided among groups peacefully for long. If these gangs are not controlled now, things might turn horribly bad in future.”

But the drug-tourism trade has grown deep tentacles here. Last month, the Goa legislative assembly released a 104-page report on the nexus among politicians, police officers and the drug lords.

“How can the government tackle the menace when such powerful people are protecting and profiting from it?” said Mickky Pacheco, who chaired the lower-house committee that wrote the report.

Many in Goa say they worry that the wave of negative publicity will tarnish the state’s sunny sheen permanently. Goa did not report significant growth in domestic tourist arrivals last year, and it is no longer among the top 10 Indian states that attract foreign tourists, according to the national government.

Monika Burnier, a Swiss tourist turned travel agent, said she discovered “paradise” in Goa 20 years ago and began working to bring in new European visitors.

“Over the years, the chartered flights with tourists from Switzerland, Denmark, Finland and Holland have stopped,” Burnier said, shaking her head in dismay. “Look at what Goa has become now. Do you blame them?”