A Scottish HIV charity would back plans to establish an unofficial drug consumption room.
HIV Scotland said it would support individuals and charities operating a community-led facility if an official safe injecting room could not be established.
The UK government has resisted calls for change in the law which would allow drug consumption rooms.
And it has refused to allow Glasgow City Council to run a pilot scheme.
The Scottish government is leading calls for a law change to tackle a drugs death crisis but UK ministers have described the proposals as a "distraction".
They say the focus should be on the dealers who "should face the full consequence of the law".
In a statement first published in the Daily Record, HIV Scotland chief executive Nathan Sparling called for leaders to work together on the issue.
"Every drug death, and every new HIV transmission is preventable," he said.
"That's why we need the UK and Scottish governments, the Lord Advocate, Police Scotland and the Crown Office and Procurator Fiscal Service to work together to ensure that a drug consumption room can become a reality in Scotland.
"If this does not happen, we will have no option but to support individuals and charities in operating community-led services that will save lives."
It follows reports that a drugs campaigner is trying to raise money to create a mobile drugs consumption room in Glasgow.
Peter Krykant told BBC Scotland's Drivetime with John Beattie that he wants to turn a van into a "safe space" where users can take their own drugs under medical supervision.
Mr Sparling said citizen-operated drug consumption rooms set up in Denmark have gone on to become state-supported facilities.
"It feels like a damning indictment of UK government policy that activists in Scotland are being forced to take action," he said.
"Setting up a citizen-operated drug consumption room comes with its own risk, financially and legally.
"These risks should not be required, given our largest health board and Glasgow City Council stand ready to open such a facility."
Drug consumption rooms have been proposed as one of a range of measures to tackle the increasing number of drug-related deaths in Scotland.
A record 1,187 people died of drug misuse in 2018, a 27% increase on the previous year.
The Scottish government said it could not condone any action which would be against the law.
A spokesman said: "We continue to urge the UK government to take action to change the law so as to allow such facilities to be established as quickly as possible, either by taking the necessary steps to allow for the set-up of these facilities, or to devolve the powers to Scotland so that we can."
The UK government confirmed it had no plans to introduce drug consumption rooms in the UK.
"Illegal drugs devastate lives and communities, and dealers should face the full consequences of the law," a spokesman said.