DO YOU NEED A CONTENT WRITER FOR YOUR BUSINESS?

Your One-Stop Solution for All Content Needs! Click here for more!
Categories: Html

Redirect from an HTML page

Share

Redirect HTML page is done using the meta refresh for fallback purposes in the head section of a HTML i.e. replace old page with the URL of the page you need to redirect to.

This is  the simplest way to Redirect HTML page i.e. one URL to another URL with the Meta Refresh tag.

We need to place this meta tag inside the <head> at the top portion of any HTML page like below:

<meta http-equiv="refresh" content="seconds; url=URL" />
<meta http-equiv="refresh" content="0; url=http://example.com/" />

Suppose, we’ve just moved our website to a new location and we need to close the old page. So, we don’t want all pages from the old site to give a 404 Not Found message. The only thing is we need to redirect those old links to the new site.

Read Also: Meta Tags in HTML

Note to remember that HTML meta refresh redirect is just a client side redirect and this is not a 301 permanent redirect. And a 0 seconds time interval is considered by Google like a hint for 301 redirect of page rank transfer.

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="refresh" content="0; url=http://example.com/" />
</head>
<body>
<p>The page has moved to:
<a href="http://example.com/">this page</a></p>
</body>
</html>
Html Developer

Published by
Html Developer
Tags: html

Recent Posts

Benefits of Manual Therapy for Faster Recovery from Muscle and Joint Pain

Pain in muscles and joints can be a problem in everyday life, whether it involves…

3 days ago

How Digital-First Brands Can Make Offline Marketing Feel Connected

Most modern businesses spend a lot of time thinking about digital touchpoints. Websites, email campaigns,…

6 days ago

X Bets on Video

While TikTok and Instagram battle for users’ attention with short vertical videos, Elon Musk’s social…

2 weeks ago

5 Reasons to use a professional mortgage broker

When you are looking to apply for a mortgage the one thing that most people…

4 weeks ago

Tips – Advanced Blackjack Strategy

Once you've memorized basic blackjack strategy, it's time to delve deeper into the game. Advanced…

1 month ago

The Modern Practice of Yoga: How Balance, Mindfulness, and Lifestyle Design Are Transforming Everyday Wellbeing

Yoga is no longer just a physical practice. Yoga is popular as a lifestyle practice.…

1 month ago