The former boss of HIV Scotland has admitted embezzling £5,000 from the charity during his time as chief executive.
Nathan Sparling, 35, spent the money on Uber journeys and Amazon deliveries including groceries, Edinburgh Sheriff Court heard.
He admitted embezzling the money between April 2019 and March 2021 in Edinburgh and elsewhere when he appeared in the dock on Friday.
HIV Scotland has since closed.
The court heard that during his time in the role, Sparling was allowed to make purchases up to the value of £50 using HIV Scotland funds if it was for charity reasons - but anything above that value required authorisation from another member of staff.
A staff member noticed a large number of taxi journeys and raised the issue with Sparling, leading to a probe.
Sparling, a former adviser to an SNP MP, was suspended from his role at the charity and then replaced.
Fiscal depute Kirsty McKenzie told the court: "During the period, a total of £5,000 was embezzled from the charity.
"£2,000 was spent on Ubers and £3,000 on Amazon packages that were delivered to his home, including groceries and technical goods.
"He was never given permission for any of these transactions."
Read more from Sky News:
Trans prisoner charged with sex assault
Man charged with murder of teacher
Sheriff John Cook asked whether Sparling had repaid any of the money and was told he had not.
The defendant's solicitor said Sparling felt a "certain amount of complacency" as he had been working at the charity for a long time, adding: "He accepts full responsibility."
The lawyer said Sparling had not been able to repay any of the money to HIV Scotland as it has since been wound up but would be willing to pay money to a similar charity.
Sheriff Cook deferred sentence until 20 May pending reports.
(c) Sky News 2026: Ex-chief executive of HIV Scotland admits embezzling £5,000 for Uber rides and Amazon d
Man jailed for religiously aggravated rape of Sikh woman
Pentagon's Falklands email touches a nerve in Britain - and makes Charles's US visit even more challenging
Millwall get apology from Westminster council after club badge featured in kids' booklet on racism
NHS doctor accused of inviting support for Hamas appears in court - as details of alleged messages heard
Benfica's Gianluca Prestianni handed six-game ban for homophobic conduct towards Vinicius Junior
Israel's Benjamin Netanyahu successfully treated for prostate cancer
Man charged with murder of headteacher who was knocked off bike
Man, 92, charged with murder of 87-year-old woman