If you’re planning to move your website, change your domain name, or restructure your URLs, setting up proper redirection is crucial. Done right, it helps preserve your SEO rankings, backlinks, and user experience.
In this comprehensive guide by HosterSale, you’ll learn how to redirect a domain using cPanel or .htaccess, without damaging your Google rankings. Whether you’re a beginner or an advanced user, this article covers everything you need.
What Is a 301 Redirect and Why It Matters
A 301 redirect is a permanent redirection from one URL to another. It informs search engines that the old page has permanently moved and that the new URL should be indexed instead. This is the best way to retain SEO value, traffic, and link equity.
Redirects are especially important when:
- You change your domain (e.g., from
olddomain.com
tonewdomain.com
) - You switch from HTTP to HTTPS
- You restructure your URLs for better SEO
If not handled properly, you could lose search rankings and confuse both users and search engines.
Method 1: Redirect Your Domain Using cPanel (Easy Way)
If you’re using a hosting plan from HosterSale, setting up a domain redirect is simple through cPanel.
Step-by-Step Instructions:
- Log in to cPanel
Go tohttps://yourdomain.com/cpanel
and sign in. - Find the Redirects Tool
In the Domains section, click on Redirects. - Configure the Redirect
- Select Permanent (301) as the type
- Choose the domain you want to redirect
- Enter the destination URL (e.g.,
https://newdomain.com
) - Choose whether to redirect with or without “www”
- Check the Wildcard Redirect box if you want to redirect all subpages
- Click “Add”
Your domain is now redirected with SEO preserved.
Recommended Hosting for Beginners
If you’re new to cPanel or managing redirects, consider one of our Beginner-Friendly Hosting Plans at HosterSale, which includes free SSL, cPanel access, and expert support.
Method 2: Redirect Using .htaccess (For Advanced Users)
For those who prefer more control, the .htaccess
file allows you to set up precise redirection rules. You’ll find .htaccess
in your domain’s public_html directory.
Redirect an Entire Domain to a New Domain
RewriteEngine On
RewriteCond %{HTTP_HOST} ^olddomain\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.olddomain\.com$
RewriteRule ^(.*)$ https://newdomain.com/$1 [R=301,L]
Redirect a Specific Page
Redirect 301 /old-page.html https://yourdomain.com/new-page.html
Redirect Non-WWW to WWW
RewriteEngine On
RewriteCond %{HTTP_HOST} ^yourdomain\.com [NC]
RewriteRule ^(.*)$ https://www.yourdomain.com/$1 [L,R=301]
Redirect WWW to Non-WWW
RewriteEngine On
RewriteCond %{HTTP_HOST} ^www\.yourdomain\.com [NC]
RewriteRule ^(.*)$ https://yourdomain.com/$1 [L,R=301]
Note: Always back up your .htaccess
file before making any changes. If you’re using LiteSpeed Web Server with HosterSale, these rules work seamlessly.
Need more flexibility? Our Advanced Hosting Plans support custom redirects, .htaccess management, and developer tools.
Redirecting a Subdomain to Another URL
Want to send blog.yourdomain.com
to a different platform or site?
- Log in to cPanel
- Click on Domains under the “Domains” section
- Find your subdomain and click Manage Redirection
- Enter the new URL and click Save
This is useful when moving sections of your site to other services like Shopify, Blogger, or WordPress.
Related: Comprehensive Guide: How to Add Domains and Subdomains in cPanel
SEO Best Practices for Redirection
Redirects can help — or hurt — your SEO. Here’s how to make sure they help:
- Always use 301 permanent redirects
- Update internal links to point to the new URL
- Submit your new sitemap to Google Search Console
- Monitor your redirects using Google Analytics
- Keep the old domain active for at least 3–6 months
- Use tools like Screaming Frog SEO Spider to detect redirect chains or loops
At HosterSale, we offer SEO-friendly hosting built on high-performance LiteSpeed servers with cPanel, CloudLinux, and 99.9% uptime — helping your redirects load fast and rank well.
Final Thoughts
Redirecting your domain is more than a technical task — it’s an essential part of protecting your website’s visibility and traffic. Whether you use cPanel for a quick redirect or .htaccess
for advanced configurations, doing it correctly ensures your visitors and search engines don’t miss a beat.
With HosterSale’s web hosting services, you get:
- Free SSL Certificates
- Fast LiteSpeed Servers
- Full cPanel Access
- One-Click Backups
- 24/7 Expert Support