Hi guys Today, we‟re going to see How you can redirect a URL in WordPress. Let‟s say you have a website like this And you have changed the url of this site lets go to our blog page And lets say you have changed the URL of this page Now After changing the url Now if you go back to our old URL you can see that the page does not exist.
Now lets say your new link is ranking on google like this Now if you open this link It will also be redirect to the new link which you have changed I‟m Bryan from website learners, and let‟s get started.
📌 𝗙𝗼𝗹𝗹𝗼𝘄 𝘁𝗵𝗲𝘀𝗲 𝘀𝗶𝗺𝗽𝗹𝗲 𝘀𝘁𝗲𝗽𝘀
Step 1 : Install the Redirection Plugin
Go to WordPress Dashboard ► Plugin’s ► Add New
Now search for ‘Redirection’ and click ‘Install’ & ‘Activate’
Step 2 : Create a Redirection
Go to WordPress Dashboard ► Tools ► Redirection
Now click ⇒ Start Setup ► Continue ► Finish Setup ► Finished
First, copy and paste the old URL of your page in the ‘Source URL’ field
in the ‘Target URL’ field, copy and paste the new URL which you saved
Once you add the old & new URLs, click ‘Add Redirect’
let’s say you’re making changes to your site
& you want to show a ‘Maintenance’ page
To do that,
Go to WordPress Dashboard ► Tools ► Redirection
Now copy and paste the URL of the page you’re working on in the ‘Source URL’ field
& in the ‘Target URL’ field, copy and paste the ‘Maintenance’ page URL.
if you want to create a ‘Maintenance’ page, watch this video ➜
Click on the ‘Settings’ icon right next to the ‘Add Redirect’ button
choose ‘Temporary Redirect’ in HTTP code & click ‘Add Redirect’
To stop the redirect,
Go to the Redirections dashboard & click ‘disable’ on the page to which you added the temporary redirect
First, let‟s see the site which we have now Here it is Now Let‟s go to this page And let‟s say you want to change this url. Just go to your dashboard Now, go to pages and click blog Now to change this url click edit And then change the URL I‟m going to change this to tech blog and click ok Now you need to copy this link later to redirect to your old URL So lets copy this And save it on our notepad you will need this link to redirect your page Once you have saved the link click “Update.”
if we go back to our blog page. And click refresh You can see that, the page doesn’t exist So, now, let’s see how you can redirect the visitors to the new link we‟re going to do this in just 2 steps. The first step is to install the redirection plugin in WordPress. So, to install the plugin, Let‟s go to our WordPress dashboard. Now go to Plugins, and click “Add New.” Here, search for a plugin called „Redirection‟. And, you will get this plugin. Now, this is the plugin which will help us redirect the URL in WordPress. So, to install the plugin, Let‟s click “Install Now.” And then click “Activate.” Now we have successfully installed the redirect plugin in WordPress. Okay.
So, once you‟ve installed the plugin, We can now go to the second step of this tutorial, Which is to create a redirection once you create a redirection when a visitor goes to your blogs page it will be automatically redirected to the new URL So, to create the redirection, First we need to set up this plugin So to set it up Just click settings. And click „start set up‟ Now click „continue‟ And then finally click „finish set up‟ So we have completed the plugin set up Now if we click „finished‟ It will take you to this page So to create a redirection for our blog page we need to enter our old blog link, here. So, to get that, Let‟s go to this tab And copy the URL.
Now, go back to your dashboard, and paste the URL here. And here we need to enter the new URL to which you want to redirect your users. So, to get that, Let‟s open the notepad. this is the new link. To which we are going to redirect our visitors So lets copy this link And paste it here. Once you‟re done, Click “Add redirect.” And as you can see, We have successfully created our new redirection now, when someone clicks on our old link, they will be redirected to the new URL. So, to check that, Let‟s go back to this page. Now if we click refresh, You can see that our old link is automatically redirected to the new URL, and our website content is now available. So, this is how you can redirect URL in WordPress, Okay.
let‟s say you‟re making some changes to your site. And, you want to show a “maintenance” page like this to your visitors, temporarily. How will you do that? So, next, let‟s see how you can add a temporary redirect to your site. Now, let‟s say you are working on your about page And you want to redirect your visitors temporarily to a maintenance page. So, to add the temporary redirect, Let‟s go to our WordPress dashboard. Now, go to Tools, and click “Redirection.” Since we‟re working on our about page, We need to enter that URL here. So to get that link, lets go to our about page copy the URL Now go back And paste it here Next we need to enter the URL of our maintenance page so to get the url Lets go to our maintenance page copy the url now go back And paste it here So, to redirect this URL temporarily, Let‟s click here. Now, go to this option and choose “Temporary Redirect.” Once you‟re done, click “Add redirect.” Now, we have successfully added the temporary redirection in WordPress. And, your about page will be redirected to your maintenance page.
So, now if we go to our website, And then, go to the about page, You can see that the URL is automatically redirected to our maintenance page.
Now, let‟s say you‟re done working on [the/your] about page, And, you want to get it your about page back on your website. So to get back your about page You need to disable the temporary redirect, which you have created So, to do that Let‟s go back to our dashboard. Here, you can see all the redirections which we have already added to our site. Now, to get your about page back on your site Just click “Disable.” And, our about page will be back.
How to Add HTML Sitemap on your website?
Now, to check that, Let‟s go to our site‟s homepage and click “About.” Here, as you can see, the temporary redirect is now removed, . And, we have got our about page back. Now, if you want to redirect your visitors to the maintenance page again, just go to your dashboard, . And You can enable the redirection from here. So, this is how you can get your page, back on your site. Okay. Now, let‟s go to the bonus part of this tutorial where we see how you can redirect your entire website to a new domain.
let’s say you have changed your current domain name to a “new domain” like this Now, how will you redirect the visitors of your old domain to the new domain So, to redirect the visitors to the new domain, Just go back to our dashboard and go to site Here, enter your new domain. And then click “Update.” Now, our site will be successfully redirected to the new domain. So, to check that, Let‟s open a new tab. And, enter our old domain name,
Now if we press enter. you can see that our domain is automatically redirected to the new domain. Okay. Now, if we go to the blog page on the old domain, you can see that this page is also redirected to the new domain with the same URL. So, this is how you can redirect your old website to a new domain. that‟s it, guys. This is how you can redirect a URL in WordPress.
== 𝗕𝗼𝗻𝘂𝘀 𝗣𝗮𝗿𝘁 ==
Now to redirect your entire website to a new domain.
Go to WordPress Dashboard ► Tools ► Redirection ► Site
in the ‘Relocate to Domain’ field, just enter your new domain and click ‘Update’
when someone enters your old domain, they will be redirected to your new domain
This is how you can redirect a URL in WordPress
👉 If you don’t understand, watch the video: Video Link
how to do a bulk redirect, there are multiple URLs that needs to redirect to new URLs
your my hero i wanted to cry of joy when this worked
Thanks, you saved my day!
Thank you
Does this redirect happen before the user load the old page or after? will I be able to collect data using an Insight Token if placed on the 'old' webpage?