Must Read : How to redirect to another page in WordPress
A page can be redirected to a new page or URL. There are different methods to achieve this. In this blog post we will deal with all these methods in details.
There is a WordPress function which can also be used and I think it is best to use WordPress function.
Here are different methods for redirect
In this method we will use meta redirect. Add following code in head section(between <head> and </head>) of your theme header.php .
<meta http-equiv="refresh" content="1; url=http://example.com/" />
http://wearecoders.net is the url where we want to redirect.
window.location object can be used to redirect current page URL to new URL using following code block. Write this block in head area(between <head> and </head>) of header.php
window.location.href = "http://wearecoders.net"