How to Redirect www to non-www
Your site should answer on one canonical address — either www or non-www, not both. A redirect consolidates them, which is cleaner for visitors and SEO.
Step-by-step
- Decide your canonical form — yourdomain.com (non-www) or www.yourdomain.com. Either is fine; just be consistent.
- Open Domains → Redirects in cPanel.
- Choose Permanent (301) and select your domain.
- Set the destination to your chosen canonical form (e.g. https://yourdomain.com).
- Choose "Redirect with or without www" as the www-redirection option, and add.
- Test both forms in a private window — the non-canonical one should 301-redirect to your chosen version. See redirects.
💡 Good to know
- Combine with forcing HTTPS so every visitor lands on one secure canonical URL.
- Update your canonical choice in Google Search Console and analytics to match.
- In WordPress, also set the Site Address to the canonical form (see site URL).