Imagine you have worked long and hard growing food for your family.

You’ve tended your fields, overcome adverse weather and finally, after months of effort, you are close to harvesting your crop that will keep you in business for a year.

And then God bounds into your field and starts eating it all.

Taking the form of a monkey, God has taken a liking to your crop and is now trampling it, feasting upon it, trashing all your work.

Would you be overjoyed? Would you sigh and accept it as God’s prerogative? Or if it happened year after year, would you finally snap, and throw a stick at God, driving him off or worse?

That’s the dilemma facing farmers each year in northern India.

There, people venerate the rhesus macaque, a small species of monkey.

It is a religious icon in India, culturally revered as a living representative of the Hindu deity Hanuman.

Rhesus macaques raid crop fields and feed on grains and vegetables

But rhesus macaques are also common agricultural pests, which along with some other species are triggering conflict between people and wildlife. The fear is that if such conflicts escalate, people may start to persecute wild animals, eventually threatening their survival.

To better understand the issue, scientists have now studied how farmers react to wild animals that damage their crops in India. Their findings are published in the European Journal of Wildlife Research.

Led by Sindhu Radhakrishna of the National Institute of Advanced Studies, Bangalore, India the researchers paid particular attention to the attitudes of farmers to macaques and how they treat them, given the monkey’s special status.

For six months they interviewed farmers living in the Bilaspur district in the outer hills of the Himalayas, in the state of Himachal Pradeshin in northern India.

Farmers were asked about the extent of the damage to their crops, which animal was responsible, and to rank the threat posed to their livelihood by the animals, and how they compared to other threats such as drought or pests.

Farmers in our study were clear that the monkey was a god still, even if it was also becoming a pest

Rhesus macaques pose a particular problem. Populations of the monkey have increased greatly across India, from just over 400,000 in 1988 to more than 3 million by 1994, when a census was conducted. The number of macaques has also doubled in the study region in the past couple of decades, and a 2013-14 census documented some 400,000 rhesus macaques in the state of Himachal Pradeshin.

Despite their relatively small size, they can have a huge impact.

“Rhesus macaques raid crop fields and feed on grains and vegetables, thereby destroying much of the season’s harvest for the farmers. These include subsistence crops such as maize and wheat as well as different kinds of fruits and vegetables that are grown as cash crops,” explains Dr Radhakrishna.

Either the monkeys feed on the crops and destroy them. Or the movement of large groups of monkeys in the fields causes enormous damage to other standing crops, adding to the financial losses of the farmer.

The surveys revealed that farmers did treat macaques differently to other animals.

Even religious tolerance can wane

“Although farmers acknowledged that the rhesus macaque had become an agricultural pest, they also continued to see it as a religious icon,” Dr Radhakrishna told BBC Earth.

“Hence although they blamed the species for bringing about financial losses and thereby affecting their livelihoods, they were also reluctant to cause the species any harm.”

“The fact that monkeys are considered a representative of the religious deity Hanuman definitely inhibits people from harming monkeys in many parts of India,” she adds. “Farmers in our study were clear that the monkey was a god still, even if it was also becoming a pest.”

Wild pigs, however, weren’t so regarded. Another major agricultural pest in northern India, wild pigs are neither revered nor tolerated for their crop-raiding activities. “Farmers appeared to have no compunction in killing them in retaliation for their crop-raiding activities,” says Dr Radhakrishna.

Yet the study comes with one important caveat.

“Even religious tolerance can wane,” she says.

“Farmers did obtain licenses to shoot monkeys, even if it was for a brief period in 2010 in Himachal Pradesh.”

That should act as a warning. The farmers surveyed generally felt the government was to blame, for not addressing the explosion in the monkey population. In Dr Radhakrishna’s experience, the farmers were remarkably tolerant of the macaques.

But if the problem of crop-raiding monkeys isn’t solved, that view might change.

And the conflict between humans and their deity might “not only affect farmers, but also threaten the long-term survival of the rhesus macaque”, says Dr Radhakrishna.

Follow Matt Walker and BBC Earth on twitter.