ONS coding system


The ONS coding system was a hierarchical code used in the United Kingdom for tabulating census and other statistical data. ONS refers to the Office for National Statistics.
It was replaced by the GSS coding system on 1 January 2011.

Code formulation

Principal authorities

The code was constructed top down from a four character code representing a unitary authority or two-tier county and district.

Electoral wards and output areas

Local government wards had a two-letter code within their local authority, and census output area an additional four digits within a ward.
12UBCambridge district
12UBGAPetersfield ward
12UBGA0001Output area: Gwydir Street

The authority and ward codes were recognised by Eurostat as local administrative unit code levels 1 and 2 within the NUTS system.

Civil parishes

An overlapping system encoded civil parish areas. Parishes were represented by an additional three digits within their local authority:

List of codes for counties and districts

The codes for counties and districts were as follows.
Also showing NUTS(3) codes thus:

Greater London

These codes became active following local government changes in 1986.00AA City of London00AB Barking and Dagenham00AC Barnet00AD Bexley00AE Brent00AF Bromley00AG Camden00AH Croydon00AJ Ealing00AK Enfield00AL Greenwich00AM Hackney00AN Hammersmith and Fulham00AP Haringey00AQ Harrow00AR Havering00AS Hillingdon00AT Hounslow00AU Islington00AW Kensington and Chelsea00AX Kingston upon Thames00AY Lambeth00AZ Lewisham00BA Merton00BB Newham00BC Redbridge00BD Richmond upon Thames00BE Southwark00BF Sutton00BG Tower Hamlets00BH Waltham Forest00BJ Wandsworth00BK Westminster

Metropolitan counties

These codes became active following local government changes in 1986.

Non-hierarchical codes for Greater London and metropolitan counties

1B Inner London1C Outer London2A Greater Manchester2B Merseyside2C South Yorkshire2D Tyne and Wear2E West Midlands2F West Yorkshire

Unitary authorities established in the 1990s

These codes became active following local government changes the 1990s.

Unitary authorities established in 2009

These codes became active following local government changes in 2009.00KB Bedford00KC Central Bedfordshire00EQ Cheshire East00EW Cheshire West and Chester00HE Cornwall00HF Isles of Scilly00EJ County Durham00EM Northumberland00GG Shropshire00HY Wiltshire

Non-metropolitan counties

08 Avon

Wales

These codes became active following local government changes in 1996.00NA Isle of Anglesey00NC Gwynedd00NE Conwy00NG Denbighshire00NJ Flintshire00NL Wrexham00NN Powys00NQ Ceredigion00NS Pembrokeshire00NU Carmarthenshire00NX Swansea00NZ Neath Port Talbot00PB Bridgend00PD Vale of Glamorgan00PF Rhondda Cynon Taff00PH Merthyr Tydfil00PK Caerphilly00PL Blaenau Gwent00PM Torfaen00PP Monmouthshire00PR Newport00PT Cardiff

Scotland

These codes became active following local government changes in 1996.00QA Aberdeen00QB Aberdeenshire00QC Angus00QD Argyll and Bute00QE Scottish Borders00QF Clackmannanshire00QG West Dunbartonshire00QH Dumfries and Galloway00QJ Dundee00QK East Ayrshire00QL East Dunbartonshire00QM East Lothian00QN East Renfrewshire00QP Edinburgh00QQ Falkirk00QR Fife00QS Glasgow00QT Highland00QU Inverclyde00QW Midlothian00QX Moray00QY North Ayrshire00QZ North Lanarkshire00RA Orkney Islands00RB Perth and Kinross00RC Renfrewshire00RD Shetland Islands00RE South Ayrshire00RF South Lanarkshire00RG Stirling00RH West Lothian00RJ Eilean Siar

Northern Ireland

95A Derry95B Limavady95C Coleraine95D Ballymoney95E Moyle95F Larne95G Ballymena95H Magherafelt95I Cookstown95J Strabane95K Omagh95L Fermanagh95M Dungannon and South Tyrone95N Craigavon95O Armagh95P Newry and Mourne95Q Banbridge95R Down95S Lisburn95T Antrim95U Newtownabbey95V Carrickfergus95W North Down95X Ards95Y Castlereagh95Z Belfast