HTML Redirect code to another page: meta refresh explained

Last updated: September 9, 2020

The HTML redirect code you’re looking for is called the “meta refresh element”: <meta http-equiv="refresh" content="0; url=$URL">

With one line of HTML code you can redirect visitors to another URL or page.

You need to place the meta refresh element in the <head>-section of a page, and it contains a parameter to instruct a browser to load another URL (refresh the page) after a certain number of seconds.

The HTML redirect code

Here’s an example of what the meta refresh redirect looks like to send a visitor to https://www.contentkingapp.com/ immediately after loading a page:

<meta http-equiv="refresh" content="0; url=https://www.contentkingapp.com/">

HTML redirects and SEO

From an SEO point of view it’s not recommended to use HTML redirects because:

  1. Search engines are slow to pick up on them than they would on 301 redirects, because they need to parse the HTML to find the HTML redirect.
  2. There’s no guarantee the redirect is picked up correctly, therefore it’s unsure if you’ll see the same amount of authority being passed on as you’d see with a 301 redirect.
  3. HTML redirects make for a slower user experience than for instance a 301 redirect.
ContentKing Academy

Read the full Academy article to learn everything about Redirects

Start your free trial

Get up and running in 20 seconds

Please enter a valid domain name (www.example.com).
  • No credit card required
  • No installation needed
  • No strings attached