Welcome to the census21api documentation!

What is this and why does it exist?

This package, census21api, is the (unofficial) Python interface to the “Create a Custom Dataset” web tool for the 2021 England and Wales Census.

The primary goal of this project is to streamline the process of accessing and working with data from the 2021 England and Wales Census API. With census21api, you can create pretty much any Census tables you like in a programmatic way.

Who made this?

The package and its documentation were developed by the 2023 cohort of Office for National Statistics data engineering and architecture apprentices – with support from the Data Science Campus.

See our citation file for a list of the original authors or our GitHub repository for all the contributors.

Where do I go now?

Our documentation follows the Diátaxis framework and is split into the following sections:

  • Tutorials are walkthroughs of projects using census21api — if you’re new, start here.
  • How-to guides are short guides with a very specific goal in mind.
  • Reference holds the technical documentation covering the details of how census21api works.