django-planet
Feb. 11, 2024

Django accessibility in 2023 and beyond

published by Tom Carrick, Thibaud Colas, Sarah Abderemane
in blog The Django weblog
original entry Django accessibility in 2023 and beyond

Happy birthday, Django accessibility team! šŸŒˆ

The team has been up and running for three years, and is now looking for new members. With a lot happening in this space, we thought we were overdue for an update on what weā€™re up to.

Django accessibility in 2023

Weā€™re very happy with the work done to date. There have been a lot of efforts to improve the accessibility of core Django features such as forms, and of the administrative interface. Beyond Django core, there has also been progress on djangoproject.com, Django packages, and community awareness via talks and events.

Django core

We made a lot of improvements this year. Django forms saw big fixes, which shipped in Django 5.0:

With forms being such a core feature of Django, reused across countless websites, those changes will lead to accessibility improvements across big parts of the web.

The admin interface also saw a lot of fixes and improvements:

Some of those improvements will reflect for everyone, and some will only be beneficial for users of specific assistive technologies, such as Contrast themes in Windows:

Django admin interface in high contrast mode, black theme
ā†’ Screenshot of the admin interface in a ā€œChange redirectā€ form, in Windows high contrast mode with the ā€œBlackā€ theme.

Can you spot the five issues in this screenshot? Though Contrast Themes isnā€™t well known, itā€™s a built-in feature of Windows which is essential for people with low vision. There is a lot of room for improvement to better support it in Django.


Weā€™ve also made a lot of progress on documenting accessibility considerations, though there is still work to be done there:

And finally tooling improvements such as running accessibility checks in the CI pipeline is still a big topic for us, with in-progress efforts to add checks in Selenium tests and standalone with Pa11y.

Django website

In 2023, the website saw its first ever accessibility audit with a focus on the homepage, as well as a good number of accessibility improvements. Those are all very welcome iterative steps in the context of user research on the usability of the website, led by 20tab.

Thank you to our website contributors Sarah Abderemane, Thibaud Colas, ontowhee, Sanyam Khurana, Hana Burtin, Paolo Melchiorre, and Tom Carrick ā¤ļø.

Accessibility in our community

Weā€™re elated to see accessibility being such a prominent topic in our community. In 2023, there were a lot of accessibility talks at Django events. There were accessibility contributors at the sprints for DjangoCon Europe, and DjangoCon US. The #accessibility channel on the Django Discord was also very active, and we got a new Accessibility forum category.

There were a lot of accessibility-focused talks at Django events:

Our very own accessibility team member Sarah Abderemane was also featured on Django Chat: Accessibility - Sarah Abderemane šŸŽ‰, while Tom and Thibaud signed up for Djangonaut Spaceā€™s first session as navigators.

Behind the scenes, the accessibility team also started maintaining a backlog of django accessibility improvement, and also publish their accessibility team meeting notes on the forum.

Django accessibility in numbers

This year, we were able to produce statistics on the accessibility of Django projects, thanks to reports from the HTTP Archive. There is clear room for improvement, with Django websites generally scoring lower than sites built with other technologies:

Median accessibility score of websites by framework, cwvtech.report, December 2023
ā†’ Median Lighthouse website accessibility score of websites by framework. Source: HTTP Archive cwvtech.report, December 2023. Next.js: 85/100, Rails: 83, ā€œAllā€: 82.5, Django: 80.5, ASP.NET: 79, Laravel: 78.5.

There is also clear data to establish exactly which accessibility issues are common on Django websites:

Difference in Lighthouse audit success rate for sites built with Django vs average site
ā†’ Difference in Lighthouse audit success rate for sites built with Django vs. average site, HTTP Archive 2023-04-01 data, Django vs. ā€œAllā€. We see 8 metrics where Django does worse than average, and 8 where it does better.

We see those numbers as a good challenge for the Django community to explore ways in which the framework could be improved. There is clear room for improvement, and we have a lot of ideas on how to go about it.

Accessibility plans for 2024

There are a lot of ways in which the accessibility of Django could be improved in 2024. Here are a few ideas that have been discussed so far, where our accessibility team is looking for help:

  • Django ecosystem accessibility audits: Testing Trac or the Forum; or popular Django packages.
  • Creating an official Django demo site: converting Tomā€™s django-admin-demo to a ready-to-use official demo.
  • Stylesheets linting: To catch and fix common issues such as small font sizes or poor focus states.
  • Accessibility in docs: A possible big docs overhaul as a Google Season of Docs project.
  • New, accessible admin components: Addressing big gaps in the admin interface.
  • User testing: Working directly with users of assistive technologies.
  • An official Django accessibility statement: On the website, loud and clear.

New members

With this roadmap of improvements in mind, our accessibility team is looking for six new members in 2024. If this sounds like the type of valuable, high-purpose work you want to contribute to ā€“ reach out on the Django Discord in #accessibility, or on the forum.

Thank you

Thank you to everyone who took part in making Django more accessible in 2023 and early 2024. You rock!

Django heart
You?

Come say hi on the forum