Moving web content leaves visitors arriving at the old URL. An HTML page can redirect them to another URL with a meta-refresh tag when you can edit the page but cannot configure an HTTP redirect.

Meta refresh runs in the browser after the original page loads. A zero-second delay sends the visitor on immediately, while a normal link lets them continue if automatic redirection is disabled. JavaScript is not required.

Google recommends an HTTP 301 or 308 redirect for a permanent move when server access is available; HTTP 302 is temporary. Google treats zero-second meta refresh as permanent and delayed meta refresh as temporary, but these remain browser-side redirects rather than HTTP status codes.

Steps to redirect an HTML page with meta refresh:

  1. Open the HTML file for the original URL in your text editor.
  2. Insert a meta-refresh tag containing your destination URL inside the page's <head> element.
    <meta http-equiv="refresh" content="0; url=https://example.com/">

    The 0 is the delay in seconds, and https://example.com/ stands for your destination URL. A full URL includes the scheme, such as https://; a relative URL such as /new-page.html points to another page on the same site. If a refresh tag already exists, replace it rather than adding a second one.

  3. Add a fallback link to the same destination inside the <body> element.
    <!doctype html>
    <html lang="en">
    <head>
      <meta charset="utf-8">
      <meta http-equiv="refresh" content="0; url=https://example.com/">
      <title>Page moved</title>
    </head>
    <body>
      <p>If you are not redirected,
        <a href="https://example.com/">continue to the new page</a>.
      </p>
    </body>
    </html>

    This complete HTML document includes both the refresh tag and the fallback link. The tag's url= value and the link's href value must point to the same destination. Existing pages can retain their other HTML.

  4. Save the HTML file.
  5. Upload the saved file to the original page's location if you edited a local copy.

    This step is unnecessary when the editor saves directly to the website.

  6. Verify that loading the original page in a browser takes you to the destination URL.

    With https://example.com/ as the destination, the address bar shows that URL and the destination displays text about its use for documentation examples. If the original page remains visible, the fallback link provides a manual route to the destination.

Share this guide