Richard Stanton — UC Berkeley
Mar 21, 2026
https://github.com/rhstanton/accessible_LaTeX
As of April 24, 2026, updated ADA rules require digital course materials—including materials on password-protected course sites—to meet accessibility standards (WCAG 2.1 Level AA).
Many instructors write course materials in LaTeX, but standard LaTeX (including Beamer) does not automatically generate accessible PDFs.
This repository provides working templates and migration guidance for creating accessible LaTeX documents that meet those requirements.
📊 Example output
The slides document is the most complete example and the best place to start.
Two templates are included:
accessible_slides.tex— accessible presentation slides usingltx-talkaccessible_article.tex— accessible article-style documents
Making LaTeX accessible requires five common steps.
These apply to both slides and articles.
If you're converting existing LaTeX/Beamer files, here's what to add:
-
At the very top (before
\documentclass):\DocumentMetadata{ pdfstandard=a-2u, pdfstandard=ua-1, pdfversion=1.7, lang=en-US, tagging=on, tagging-setup={ math/alt/use, math/mathml/AF=false, math/tex/AF=false, math/mathml/sources= } } -
In every
\includegraphics:\includegraphics[alt={Description of image}]{figure} -
Before every table:
\tagpdfsetup{table/header-rows={1}} -
Change compiler to LuaLaTeX
- Change document class:
\documentclass[frame-title-arg]{ltx-talk} % was \documentclass{beamer}
- Keep your
\begin{frame}environments as-is - Remove Beamer themes/templates/colors
- Recreate styling with standard LaTeX packages
- Keep your
- Add
\DocumentMetadatabefore\documentclass - Tag images with alt text
- Tag table header rows
- Use accessible color contrast
- Compile with LuaLaTeX
| Document Type | Requirement |
|---|---|
| Articles | Keep article, report, or book |
| Slides | Replace beamer with ltx-talk |
\DocumentMetadata{
pdfstandard=a-2u, % PDF/A archival standard
pdfstandard=ua-1, % PDF/UA accessibility standard
pdfversion=1.7,
lang=en-US,
tagging=on,
tagging-setup={
math/alt/use,
math/mathml/AF=false,
math/tex/AF=false,
math/mathml/sources=
}
}
\documentclass[frame-title-arg]{ltx-talk}
\tagpdfsetup{role/new-tag=frametitle/H1}
\ExplSyntaxOn
\AtBeginDocument{
\NewTaggingSocketPlug{talk/sec/title}{none}{}
\AssignTaggingSocketPlug{talk/sec/title}{none}
}
\ExplSyntaxOff
\title{Accessible LaTeX Slides}
\author{Richard Stanton}
\begin{document}
\maketitle
\begin{frame}{Example Slide}
Accessible math: \(E = mc^2\)
\includegraphics[alt={Example image}]{capybara}
\end{frame}
\end{document}Compile with:
lualatex example.texFor full configuration and validator workarounds, see accessible_slides.tex.
This repository is intended for:
- instructors creating course materials in LaTeX
- researchers preparing accessible PDFs
- users migrating existing LaTeX documents to WCAG-compliant PDFs
| Feature | Articles | Slides |
|---|---|---|
| Document class | article, report, book |
ltx-talk |
| Class change needed | No | Yes |
| Frame environment | N/A | Yes |
| Beamer themes | N/A | Not supported |
| Accessibility steps | Same for both | Same for both |
Both templates use infrastructure from the LaTeX Tagging Project.
https://latex3.github.io/tagging-project/
This provides:
- automatic PDF tagging
- MathML generation
- structured headings
- accessible lists and tables
- PDF/A archival compatibility
Requirements:
- LaTeX kernel 2025-11-01 or later
- TeX Live 2023+ with updates applied
Clone the repository:
git clone https://github.com/rhstanton/accessible_LaTeX.git
cd accessible_LaTeXCompile:
lualatex accessible_slides.texor
lualatex accessible_article.texMinimum environment:
- TeX Live 2023+
- LaTeX kernel 2025-11-01+
- LuaLaTeX
Update packages if necessary:
tlmgr update --allThis template works on Overleaf using the Labs environment.
Steps:
- Join the Overleaf Labs program
- Enable Rolling TeX Live releases
- Set compiler to LuaLaTeX
https://www.overleaf.com/labs/participate
accessible_article.tex
accessible_slides.tex
BerkeleyHaas.png
capybara.jpg
rsbibsplit.lua
sample.bib
slide_utils.sty
strip_af.py
.latexmkrc
| File | Purpose |
|---|---|
| accessible_article.tex | example accessible article |
| accessible_slides.tex | example accessible slides |
| BerkeleyHaas.png | Berkeley Haas logo |
| capybara.jpg | sample figure |
| rsbibsplit.lua | LUA code to split bibliography across multiple slides |
| sample.bib | sample bibliography file |
| slide_utils.sty | additional slide utilities |
| strip_af.py | optional validator cleanup script |
| .latexmkrc | build configuration |
Both templates demonstrate:
- tagged document structure
- accessible math (MathML)
- accessible tables
- alt text for images
- accessible color contrast
- accessible links
Every accessible document must begin with a \DocumentMetadata{...} block before \documentclass.
\DocumentMetadata{
pdfstandard=a-2u,
pdfstandard=ua-1,
pdfversion=1.7,
lang=en-US,
tagging=on,
tagging-setup={
math/alt/use,
math/mathml/AF=false,
math/tex/AF=false,
math/mathml/sources=
}
}For a complete working example in context, see accessible_slides.tex.
A minimal example may compile, but the recommended configuration is the one used in accessible_slides.tex.
Important distinction:
-
PDF tagging (
tagging=on): Creates structure tree for screen readers- REQUIRED for accessibility compliance
- Happens automatically once enabled
-
PDF bookmarks: Navigation outline in the left pane
- NOT required for accessibility
- Do NOT generate automatically from
tagging=on - Require custom code (see
accessible_slides.texfor example) - For articles, use
\tableofcontentsor thebookmarkpackage
If you want bookmarks in your PDFs, you need to add bookmark-generation code yourself. The slides template includes example code for this.
Some validators require a document title in the XMP metadata.
\title{Document title}
\author{Author name}\includegraphics[alt={Description of image}]{file}\tagpdfsetup{table/header-rows={1}}Use LuaLaTeX, not XeLaTeX or pdfLaTeX.
Beamer themes and templates do not transfer directly.
accessible_slides.tex is the most complete example.
Different accessibility tools check different aspects of a PDF.
Ally checks usability and accessibility structure.
veraPDF checks strict PDF/A archival conformance.
Lbl and LBody – Failed
This is a known issue with Acrobat’s accessibility checker and can generally be ignored.
PAC may report:
Table header cell has no associated subcells
even when header rows are tagged correctly.
Recommended workflow:
- Run multiple validators.
- Compare findings.
- Investigate structural issues but treat isolated warnings cautiously.
pip install pikepdf
python strip_af.py build/yourfile.pdfUpgrade to TeX Live 2023+.
Update your TeX distribution.
LuaLaTeX is slower than pdfLaTeX.
- TeX Live 2025
- MacTeX
- Overleaf Rolling TeX Live
- LuaLaTeX
LaTeX Tagging Project
https://latex3.github.io/tagging-project/
WCAG 2.1
https://www.w3.org/WAI/standards-guidelines/wcag/
- Andrei Kurbatov — https://github.com/andreigithubK
Released under CC0 1.0 Universal.
No restrictions. No warranty.