On a recent project, we were required to create a drop down list to display the UK’s counties as part of a web form collecting users addresses. We assumed that this would be a pretty standard task and that there would be an abundance of pre-configured lists available on the Internet for download. After about an hour of research, it became clear that it was not going to be that simple. All of the lists we unearthed were either incomplete or out of date and it seems that we were not the first developers to run into this trouble.
You can see how it is easy to get it wrong though, take a look at the Wikipedia list of UK counties. The list of counties has changed quite considerably over time, especially in Wales.
As we were only interested in postal addresses for the web form, we decided it would be quicker and easier to compile our own list using the postal county data in this Wikipedia article. So here is a zipped file containing the HTML list as well as a XML list we created of the current UK postal counties. We hope this helps you out in some way. It may be worth just keeping these lists on file somewhere, you never know when you may need them.
UKCounties.zip 1.55kb
Resources
Comments
Comments are closed.
25th March 2009 at 10:10 am
hi there Ian
Interesting article, we had a similar situation at work with a list of countries, which admittedly can change more often than counties.
Very kind of you to upload the list, and I look forward to further tutorials from you!
all the best
Stuart
18th May 2009 at 1:20 pm
Hi,
what about uk *postal codes* for that counties? 😉
18th May 2009 at 1:45 pm
Hi oriol,
Unfortunately not, by this may be of assistance: http://jamazon.co.uk/web/2008/07/24/full-uk-postcode-database-for-free/.
Thanks!
23rd October 2009 at 12:17 pm
Hello Ian, thanks for the list and for sharing. Very useful.
Mike
29th November 2009 at 3:55 pm
Avon no longer exists!!!
9th January 2010 at 10:41 am
I’m not sure the listing for Wales are correct..
Pembrokeshire?
10th January 2010 at 7:56 pm
Hi Sean,
I have listed the postal counties, not the actual geographical counties as it is probably more useful when creating address forms. Take a look at the Wikipedia article.
Thanks,
Ian
30th January 2011 at 12:14 pm
Many thanks for the list
12th September 2011 at 9:01 am
Great List.
Saved me hours of research.
I’ve Cut/Pasted and formatted it into Excel 2003 / 2007 if anyone wants it?
27th September 2011 at 2:39 pm
Yes please Kevin, that would be really helpful!
nick.harvey@seafarers-uk.org
31st October 2011 at 10:34 am
Hi Kevin,
Could you also send me the excell version please. Thank you in advance. sadik.ibrahim@hotmail.com
7th November 2011 at 2:58 pm
Hello Kevin,
May I also have the excel version of the postal codes please? Many thanks.
moleena@hotmail.com
13th June 2012 at 4:01 pm
Hello Kevin,
May I have the excel version of the postal codes please ? Thanks in advance.
12th October 2012 at 12:00 pm
Hi Kevin,
Could I also ask you for a copy of the post code data please?
Many thanks
28th February 2013 at 7:01 pm
can you help me with the excel foramt i need to make my sale sheet updates on county basis please
regards
ashish
19th December 2011 at 8:31 pm
Kevin,
Many thanks for publishing this, much appreciated.
I will add you to the links page of the site I’ve created.
12th January 2012 at 10:46 pm
thanks – just saved me a lot of work!
28th February 2012 at 11:19 pm
you’re missing Greater Manchester
3rd July 2012 at 7:10 pm
Hello Kevin,
May I also have the excel version of the postal codes please? Many thanks.
sambrekar.ishan@gmail.com
13th July 2012 at 5:28 pm
Thanks for sharing!
5th August 2012 at 8:07 am
Hi Ian(?)
Do you know how I would go about creating an html link from each town to a specific area of a site I am developing for a client? (i.e. Customer clicks their postal town to be taken to area of the site specific to that town?)
Any guidance would be greatly appreciated.
Cheers
Gary
8th August 2012 at 1:40 pm
Hi,
Really use full, saved loads of time, thanks for making it available.
Kind regards
7th January 2013 at 6:58 pm
Hello and thank you!
Like many others this has just saved me a whole heap of time trying to pull something together for an address database we are in the process of setting up with our colleauges in the US (who aren’t that familiar with UK address formats and counties).
A version in Excel would be very much appreciated.
Cheers,
Carolyn
31st January 2013 at 8:26 am
Thanks! Might need this for a project – really helpful
31st January 2013 at 9:24 am
Dear all concerned.
The Excel sheet that I created was done September 2011.
I am uncertain if I still have the File as I was working for a Different employer at time and it may have been saved on their Servers.
I will have a look at home over the next couple of days and get back to you all.
Kind regards,
Kevin.
16th February 2013 at 12:19 pm
As like many others I’ve been looking for a definitive list of UK counties. Found this site but the list is not correct.
Key error (for me as I live in the area) is that ‘Avon’ has not existed since 1996 when it was replaced by:
Bristol (City Area)
North Somerset
South Gloucestershire
Bath & North East Somerset (BANES)
If you’re listing ‘Avon’ on a website as part of the address then it’s incorrect.
31st March 2013 at 5:14 pm
As from 1996 I think it is counties have not been required as part of the address. As from this year I think it is the Royal Mail will stop giving out counties included previously in the address data base. They are out of date, inaccurate (take a look at London) and cause confusion. The best way to address a letter to Great Britain is just street, town and post code.
6th April 2013 at 5:40 pm
You have London but not Greater London. Middlesx hasn’t existed since 1965! From 1996 the has been no need to use postal counties as they do not reflect geographical counties and casue a lot of confusion.
The Royal Mail Postcode finder does not require no givecounties now and by creating this you really are perpetuatingthe confusion that has occurred for at least fifty years.
All are now know as former postal counties;
http://en.wikipedia.org/wiki/Postal_counties_of_the_United_Kingdom
5th June 2013 at 10:50 pm
Fantastic stuff Ian, you’ve saved me a fair bit of time there.
Many thanks, the beers are on me! 🙂
6th June 2013 at 3:46 pm
Just curious, but why are postal counties which no longer exist needed? There are discrepancies in the list.
1 Any Street (street)
Somewheretown (town)
AB1 2CD (postcode)
is all that is needed in an address. That is all the Royal Mail looks at.
18th June 2013 at 9:28 am
Thanks for the list. It also saved me time too!
5th August 2014 at 6:50 pm
@Balham
You don’t mention post town being required as part of the UK address. Yet, the Royal Mail’s website says this is required:
Street Address
Locality
Post Town
Post Code
3rd March 2015 at 5:13 pm
Thanks a mil for that, Wikipedia is a mine-field!! An example of “too” much information!
27th March 2015 at 3:39 pm
But this is very outdated too. Mid Glamorgan was abolished in 1996 for example.
You are correct that this task is becoming a nightmare. I can’t find anyone with an up to date list.
27th March 2015 at 4:04 pm
Try this:
Avon
Bedfordshire
Berkshire
Bristol
Buckinghamshire
Cambridgeshire
Cheshire
Cleveland
Cornwall
Cumbria
Derbyshire
Devon
Dorset
Durham
East Riding of Yorkshire
East Sussex
Essex
Gloucestershire
Greater Manchester
Hampshire
Herefordshire
Hertfordshire
Humberside
Isle of Wight
Isles of Scilly
Kent
Lancashire
Leicestershire
Lincolnshire
London
Merseyside
Middlesex
Norfolk
North Yorkshire
North East Lincolnshire
Northamptonshire
Northumberland
Nottinghamshire
Oxfordshire
Rutland
Shropshire
Somerset
South Yorkshire
Staffordshire
Suffolk
Surrey
Tyne and Wear
Warwickshire
West Midlands
West Sussex
West Yorkshire
Wiltshire
Worcestershire
Antrim
Armagh
Down
Fermanagh
Londonderry
Tyrone
Aberdeen City
Aberdeenshire
Angus
Argyll and Bute
Banffshire
Borders
Clackmannan
Dumfries and Galloway
East Ayrshire
East Dunbartonshire
East Lothian
East Renfrewshire
Edinburgh City
Falkirk
Fife
Glasgow (City of)
Highland
Inverclyde
Midlothian
Moray
North Ayrshire
North Lanarkshire
Orkney
Perthshire and Kinross
Renfrewshire
Roxburghshire
Shetland
South Ayrshire
South Lanarkshire
Stirling
West Dunbartonshire
West Lothian
Western Isles
Blaenau Gwent
Bridgend
Caerphilly
Cardiff
Carmarthenshire
Ceredigion
Conwy
Denbighshire
Flintshire
Gwynedd
Isle of Anglesey
Merthyr Tydfil
Monmouthshire
Neath Port Talbot
Newport
Pembrokeshire
Powys
Rhondda Cynon Taff
Swansea
Torfaen
The Vale of Glamorgan
Wrexham
Channel Islands
Isle of Man