Ensures <meta http-equiv="refresh"> Is Not Used for Delayed Refresh

Photo of Researcher
Yotam Flohr
Researcher
Blind Hearing Mobility
WCAG 2.1 Level A

Written and researched for humans by humans

Photo of Researcher
Yotam Flohr
Researcher
Photo of Expert
Ritvik Shrivastava
Expertly reviewed by
Comments: 0
Your entire domain
Get detailed instructions on how to resolve every accessibility issue on your website

An HTML document must not use <meta http-equiv=”refresh”> with a refresh time of less than 20 hours.

Why It Matters

Users don’t expect a page to refresh automatically, so it can be disorientating. Refreshing a page will also move the programmatic focus back to the top of the page, creating a frustrating user experience.

If the <meta> element is designed to redirect the user to a new location, server-side processes should be used instead of client-side. 

Fixing the Issue

Developers should either remove the http-equiv=”refresh” attribute from each relevant meta element or increase the refresh time to more than 20 hours.

If the purpose of the <meta> element is to refresh the page, this should be handled through JavaScript. Additional scripting should also be used to provide users with the ability to pause the refresh, extend the time between refreshes, or to turn the refresh off entirely.

Bad Code Example

Code example
<meta http-equiv="refresh" content="10" url="http://www.yourdomain.com/index.html"> Copy

Test Cases

For more examples, visit the following pages in W3C’s GitHub’s ATC Rules library: