The poll, carried out for the Scottish Environment Link (ScotLink) coalition, found 88 per cent of people consider farming to be a key industry for Scotland.
Those majority of those questioned are in favour of continued financial support for farmers but believe it should be conditional on measures to benefit the planet and deliver public good.
More than three-quarters said payments should hinge on farmers’ efforts to support wildlife and reduce harm to the environment.
A similar number feel farmers should be encouraged to cut pollution and use of pesticides and antibiotics and to make sure more home-grown produce goes towards feeding children and hospital patients.
More than half of those polled, regardless of their political beliefs, also want the Scottish Government to decide on the country’s farming policy – only one in six said Westminster should have control and one in four that it should be a shared responsibility.
Farmers currently receive financial support through the EU’s Common Agricultural Policy (CAP), which sees £600 million of public money spent annually in Scotland.
There are currently two tiers of funding. Pillar 1, which receives 70 per cent of Scottish CAP spending, sees farmers paid for every hectare of land they farm. Pillar 2, which accounts for the remaining 30 per cent, covers wider rural development goals such as organic farming, tree-planting, wildlife-friendly practices and public access.
Westminster has said it will guarantee current EU levels of funding for farmers for three years following Brexit.
Environmentalists believe the latest findings should be used to help develop government policy for the future of farming in Scotland.
Vicki Swales, head of land use policy for RSPB Scotland and convener of ScotLink’s Land Group, said: “We think it is right that public money is used to support farming and crofting but it must be well targeted and focused on delivering public goods.
“That means supporting farmers and crofters for managing their land in ways that are good for wildlife, reduces climate-warming greenhouse gases and improves water quality, amongst other things. This poll shows that is what the majority of the public also want. We urge the Scottish Government to develop farming policy now that will deliver this.”
Pete Ritchie, leader of ScotLink’s food and farming subgroup, added: “We knew the Scottish public were concerned about the environment, but this poll shows very high levels of cross-party support for a food and farming policy which delivers public goods and a strong local food economy. The forthcoming Good Food Nation Bill offers a great opportunity to refocus public support for farming on delivering public value.”
Farmers have also welcomed the findings.
NFU Scotland president Andrew McCornick said: “The findings from this survey can be broadly seen as being very positive for Scottish farming, showing that the public have a great deal of faith and trust in us as both producers of high-quality food and drink, as well as custodians of the countryside and natural environment.
“There seems to be a direct link between what the union has been saying for some time now and the priorities highlighted in this survey.”
He said public support for helping farmers to sell more food locally and earn a minimum level of income are particularly encouraging.
RSPB Scotland’s Loch Gruinart nature reserve on Islay.
Herds of cattle and sheep graze the land to benefit birds, butterflies, bats and other creatures, then are later sold for meat to help fund the work.
Dave Maynard, community information and tourism officer at Loch Gruinart, said: “Seasonal farming requirements and diverse wildlife habitat management methods synchronise to create a fascinating combination of successful agricultural and conservation practices. Farming and wildlife conservation really do go hand-in-hand here.”