Score:-1

www.website.com works even if there is no A dns record for it

ke flag

I was checking a domain DNS records and they are the following: relevant dns records

I can connect to this website only at www.website.it, not at website.it (it automatically redirects in firefox). My understanding was that there needed to be an alias record, or a A record with www.website.it pointing to the same server. However that DNS record shows a single A record, without a www A record or CNAME.

So how come i can type www.website.it and be connected even though www is not in the DNS record? And why can't i connect to https://website.it even if the IP is on the DNS record? i assume this has something to do with the webserver hosting configuration?

Thanks in advance

Nikita Kipriyanov avatar
za flag
The screenshot is useless. One can always say that there are more records (e.g. NS, MX, SOA) but those are off page. Who can guarantee you didn't left something relevant off page too? For example, a wildcard record. // Also, who said your domain was delegated to this server at all? Maybe you set something there, but this server is not queried, instead the domain is delegated to some another server and you have to check that server's contents. Check with `whois your-domain` first, also `dig -t ns your-domain`, then ensure these servers are the ones where you are setting up records.
Patrick Mevzek avatar
cn flag
"So how come i can type www.website.it and be connected even though www is not in the DNS record? " This is just not possible. So until you provide the real names, noone can explain things to you.
user3260772 avatar
ke flag
No other relevant information there, i just assumed that in website.it domain records i would find something that would lead me to www.website.it. But apparently i had to search for it separately
Score:0
us flag

Can the ip be resolved in both address (website.it and www.website.it) with nslookup? You can use command line or online tool like https://www.nslookup.io to do that.

You mention that when going to website.it, it will redirect to www.website.it

Seem it is caused by the server / web configuration...

Nikita Kipriyanov avatar
za flag
When there is no DNS record for www which directs it to some web server, there is no web server to put a redirect.
user3260772 avatar
ke flag
Thanks, i had assumed that the A or CNAME record for www would be in the website.it domain records. I looked up those for www.website.it and i found the CNAME record pointing to website.it, and the corrisponding A record. So this clears it up. A further question would be, now that i've identified the IP address to which www.website.it points to, shouldn't i be able to connect to the website by typing ht tps://ipaddress in the browser adress bar? because this doesn't seem to work while "ht tps://www.website.it" does work. Thanks again
Hugo Tse avatar
us flag
What is the status of the response? What do you mean "cannot connect to website.it"? it is 200 or 500 or other thing else? or just redirected to www? I guess it is related to the server / application. it is possible that there are some config say only serve the specific hostname (eg: https://www.website.it) or do redirect when missing www. You can check the access log to debug the problem. If the redirection is set, you may see 2 requests on the log: 301 / 302 (non www) then 200 (www). You need to test it with privacy mode / clear you browser cache because 301 redirection may be cached.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.