Neither www.example.com or example.com work - DNS issue

I am trying to make BOTH www.example.com and example.com work on my website, but not having much luck.

The domain is: ukfirecalculator.com

Any ideas?
Thank you

https://ukfirecalculator.com seems to work, https://www.ukfirecalculator.com times out.

What have you configured for www? (both are proxied)
https://cf.sjr.org.uk/tools/check?1b10f8e7dfe84dd7a74ed94586656c2c#dns

What do you want to happen?

  1. Make https://ukfirecalculator.com and https://www.ukfirecalculator.com both work - users will see https://ukfirecalculator.com or https://www.ukfirecalculator.com in the browser depending on which they visit.
  2. Redirect everything to https://ukfirecalculator.com, going to https://www.ukfirecalculator.com takes visitors to https://ukfirecalculator.com.
  3. Redirect everything to https://www.ukfirecalculator.com, going to https://ukfirecalculator.com takes visitors to https://www.ukfirecalculator.com.

I recommend #3. #1 splits traffic across two “sites” and means sites and links can be inconsistent. #3 is best if you have to CNAME to your hosting (since you can’t CNAME the domain in a way that can be seen by the hosting if that is a requirement, so #2 won’t work if that is the case).

#3 sounds like a smart implementation. How would I go about setting that up? Many thanks

Make sure the DNS record for www is correct and working first so you can get to www.ukfirecalculator.com in your browser (it isn’t at the moment, so get that working before doing anything else). It should point by A/AAAA records or a CNAME record to your hosting. Ensure your hosting is set to work for www.ukfirecalculator.com.

Once working, you can delete any DNS entries for ukfirecalculator.com. Then create a record for @ that is proxied and is A 192.0.2.1 or AAAA 100::.

Then create a redirect rule here…
https://dash.cloudflare.com/?to=/:account/:zone/rules/redirect-rules
…by copying this example exactly…

changing:
smallshop.example.com to ukfirecalculator.com and
globalstore.example.net to www.ukfirecalculator.com

Ensure your SSL/TLS settings are set to “Full (strict)” here…
https://dash.cloudflare.com/?to=/:account/:zone/ssl-tls

Regarding getting www.ukfirecalculator.com to work, using a CNAME record, there are a few fields that require values in the DNS.

Type: CNAME
Hosting: the url of the source code, where it’s actually hosted? Does this go here?
Content: I’m not sure what to put here?
Also, does this DNS record need to be proxied?

Thank you

The CNAME will be whatever your host asks you to set. They may just give you A or AAAA addresses instead. If so, use those - they should be the same as you used for @ (ukfirecalculator.com).

I’ve attached the DNS for the CNAME that I used, and the result is an invalid SSL certificate error that I now get when I navigate towww.ukfirecalculator.com:

Where have I gone wrong with the CNAME DNS configuration? Thanks

This is what I now see when I navigate to www.ukfirecalculator.com:

Check with your hosting that the SSL certificate there covers *.ukfirecalculator.com or www.ukfirecalculator.com as well as ukfirecalculator.com.

If not, and they can’t do it, things will have to be set up the other way round.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.