Skip to content

Detect redirects made through the HTTP Refresh response header #1697

Description

@nc9

Problem

A page can redirect with a Refresh: 0; url=... response header. It behaves like a meta refresh: the browser loads the page and then moves on, search engines treat it as a weaker signal than a 301, and people using assistive technology lose their place. a11y/meta-refresh only reads the <meta http-equiv="refresh"> tag, so a refresh sent as a header is not reported anywhere.

Proposal

Report a Refresh response header the same way the meta tag is reported today, in a11y/meta-refresh.

Acceptance Criteria

  • A page served with Refresh: 0; url=<other URL> is reported, and the finding names the header and the target URL.
  • A Refresh header with a delay and a target is reported with the delay shown.
  • A Refresh header with no URL (a timed reload of the same page) is reported as a reload, not a redirect.
  • The header name is matched in any letter case.
  • A page with both the header and the meta tag produces one finding that names both sources.
  • Pages with neither get the same result as before this change.
  • The solution text recommends a 301 or 308 redirect.
  • The docs page for a11y/meta-refresh describes the header case.

Activity

  1. added
    enhancement
    size: S
    rules
    on Nov 11, 2026
  2. added theissue type on Nov 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementrulessize: S

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions