There are several ways to redirect an HTML page to another page. HTML Redirect uses <meta> tag with the http-equiv attribute to redirect the page.

Enter the URL of the page to redirect:
Generated HTML Code


How do you redirect an HTML page?

You can use the HTML <meta> tag with the http-equiv attribute set to create a simple page redirection. Setting http-equiv="refresh" tells the browser to refresh the page.

        <!DOCTYPE html>
        <html>
        <head>
            <meta http-equiv="refresh" content="5;url=https://www.iplocation.net">
        </head>
        <body>
            <p>If you are not redirected, <a href="https://www.iplocation.net.net">click here</a>.</p>
        </body>
        </html>
      

The attributes used with the <meta> tag define its behaviors.

  • http-equiv="refresh": The http-equiv attribute provides an HTTP header for the value of the content attribute.
  • content="5;url=https://www.iplocation.net": The content attribute specifies the page should be refreshed after 5 seconds, and the page should be redirected to https://www.iplocation.net.

Meta refresh is one way to redirect a page, but for better user experience, consider alternatives such as .htaccess, server-side programming, or JavaScript.