The NHS in England spent more than £440m last year on painkillers.
Figures also show that some doctors spent thousands of pounds prescribing over-the-counter painkillers and flu medication like Anadin and Lemsip.
On average, health trusts in England spent £8.80 per head of population on analgesics.
But in some northern towns and cities the figure was as high as £15, while in parts of the south it was as low as £3.26 per head.
Using figures from the NHS Information Centre and the Office for National Statistics, data analysis firm SSentif found some large differences between the average amount spent on painkillers.
The biggest spenders were Middlesbrough, Hartlepool, Rochdale and Blackpool, where painkiller prescription bills in primary care trusts (PCTs) averaged £2.3m.
That is more than double the amount spent in Richmond and Twickenham, Camden and Westminster.
The analysis also showed that across England just over £3,000 was spent on prescriptions for cold and flu remedies like Lemsip and Beechams Powders.
More than £59,000 was spent on over-the-counter painkillers like Anadin and Panadol.
Researchers looked for a link between painkiller prescribing, deprivation and old age.
In the south they found a strong link between prescribing painkillers and age, but almost no link with deprivation.
In the north the link with deprivation was stronger but there was no link to age.
'Good of patients'
Judy Aldred, managing director of SSentif, said that spending on painkillers in the NHS had grown steadily.
"At the moment, the responsibility for the prescribing budget lies with primary care trusts but this is about to change. PCTs are phasing out and GPs are being given greater responsibility, including the management of their own prescribing budgets.
"Although the figures involved were comparatively low, it was concerning to see products such as Lemsip and even Alka-Seltzer XS offered on prescription.
"When GPs begin shouldering the responsibility for prescribing costs, it will be interesting to see if this continues."
But the chair of the Royal College of General Practitioners, Dr Clare Gerada, said GPs were not prescribing painkillers without cause.
"There are very many reasons why GPs prescribe painkillers, including - but not limited to - the changing and increased needs of our ageing population, and the improved use of painkillers themselves, for example in alleviating the symptoms of osteoporosis and osteoarthritis.
"GPs understand the importance of responsible prescribing, and do so in accordance with the standards laid out by the British National Formulary. GPs do not prescribe just for the sake of it; they do it for the good of their patients."
A spokesman for the Department of Health added: "It is important that those living with pain should be able to obtain adequate relief. However the decision to prescribe pain relief must be clinically based on the assessment of the patient's needs.
"There are many factors that affect the number of prescriptions for painkillers dispensed in one particular area and no one factor can be looked at in isolation."