The Royal Bank of Scotland in the City of London. Photograph: Matt Dunham/AP

The taxpayer begins 2010 with a loss of more than £26bn on its stakes in Lloyds Banking Group and Royal Bank of Scotland, which were bailed out at the height of the banking crisis, illustrating the scale of the problem the government faces in selling its holdings in the two banks.

The taxpayers' pain is greatest in RBS because of the sheer size of the stake – about 84% – and because the government is nursing a 20p loss on each of the shares it is holding. The shares ended the year at 29.2p – well below the 50p at which the taxpayer begins to break even.

Shares in the Edinburgh-based bank were the worst performer in the FTSE 100 in 2009, losing 40%, while those in Lloyds were the sixth worst, losing more than 18%. Shares in Lloyds ended at 50.69p, almost 25p less than the 74p at which the National Audit Office believes is the average "buy in" price for the taxpayer on its 43% shareholding. At these levels, the taxpayer is losing more than £20bn on its shares in RBS and more than £6bn on its holding in Lloyds Banking Group.

The loss is even wider than the £18bn calculated by the NAO on 27 November for the holdings in the two banks, which have both incurred falls in their share prices since the watchdog conducted its detailed analysis into bank bailouts. At the time of the NAO calculation, RBS was trading at 35p and Lloyds at 59p.

Both share prices have endured a turbulent ride in 2009. Early in the year, when shares in Barclays were also pummelled on concerns about the strength of the banking sector, RBS shares plummeted to as little as 10p. Lloyds, whose shares have been recalibrated during the year because of its record-breaking £13.5bn rights issue last month, fell to a low of 16p.

But, in the autumn, the taxpayer was feeling much less pain, briefly enjoying profits on its shareholding as RBS touched 58p and Lloyds 85p.

According to the NAO, for every 10p rise in the share price of RBS, the taxpayer receives an extra £9bn for its stake and an extra £3bn for every 10p move in Lloyds.

The NAO concluded in early December that the government was right to bail out the banks, saying it was difficult to imagine the consequences for the economy and society if a major bank had collapsed.

Amyas Morse, head of the NAO, said then: "The big question is what all of this will eventually cost the taxpayer. This will take time to answer. What we do know is that how the eventual sale of RBS and Lloyds is managed will be crucial to protecting the public interest.

"The structure of the UK banking system has changed beyond recognition. When it comes to selling its stakes in the banks, the government has to be mindful of the proceeds for the taxpayer but also of the implications for competition in the UK market, so customers get a fair deal."

Ian Gordon, banks analyst at Exane BNP Paribas, described hopes of the government selling its stakes at a profit as a "distant dream". Many analysts believe UK Financial Investments, the body that looks after the state shares in the bailed-out banks, will not begin selling off shares at a loss.

Gordon said last month that "technical issues around how and when UKFI manages a sell-down of its shareholding should be substantially irrelevant," for Lloyds in 2010. He says the taxpayer has put £20.9bn into Lloyds shares and £45.8bn in RBS.