My domain works without www but not with it
example.com and www.example.com are two separate names in DNS. Each needs its own record. If one works and the other doesn’t, a record is usually missing or pointing to the wrong place.
Check the records
Section titled “Check the records”In the client area go to Domains → Manage DNS and edit your domain, or use cPanel’s Zone Editor. You need:
| Name | Type | Value |
|---|---|---|
@ |
A | Your hosting IP address |
www |
CNAME | example.com (your domain) |
Add whichever is missing. Remove any other A, AAAA or CNAME record for www that points somewhere else.
If your website is on Shopify, Wix or another platform, use the values that platform gives you. See Connecting your domain to website builders.
Check that the domain is added to your hosting
Section titled “Check that the domain is added to your hosting”In cPanel, open Domains and make sure your domain is listed. cPanel serves both example.com and www.example.com for every domain added there.
Check SSL
Section titled “Check SSL”If www shows a security warning, the SSL certificate may not cover it yet. Open SSL/TLS Status in cPanel and click Run AutoSSL. Once the DNS record works, AutoSSL includes www automatically.
Pick one main address
Section titled “Pick one main address”It’s best for search engines if your site uses one address and redirects the other to it:
- WordPress: set your preferred address in Settings → General. WordPress redirects the other version automatically.
- Other sites: add a redirect in cPanel’s Redirects tool, or in
.htaccess. See Adding or removing the www prefix in domain URLs.
Allow a few hours for DNS changes to spread. See DNS propagation explained.