Why it matters
- People with low vision zoom a page with two fingers to read it. A viewport meta with
user-scalable=noormaximum-scale=1tells the browser not to let them. - WCAG 2.2 asks that text can be resized up to 200 percent without loss of content or function (success criterion 1.4.4, level AA).
- Some browsers now ignore the setting, but others still obey it, so the page is locked for some of its visitors.
Example
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
How to fix
Remove user-scalable=no and maximum-scale, or set maximum-scale to 2 or more:
html
<meta name="viewport" content="width=device-width, initial-scale=1" />- If the setting was there to stop a form field from zooming on focus, give the field a font size of 16 pixels instead.
How we detect
- We render the page and run axe-core 4.13.0's
meta-viewportrule in each engine. - It reports a viewport meta with
user-scalable=no(or0), or amaximum-scalebelow 2. - It does not apply to pages without a viewport meta;
viewport-missingjudges those.