3

I forwarded a Bluehost subdomain to my home server's IP address. When I enter the subdomain in my browser's address bar, it redirects fine, but it shows the numerical IP address and not the subdomain name.

I forwarded a domain in Godaddy this way, and they offered a checkbox to forward with masking. Masking works.

I don't see a masking option with Bluehost. Is there a way to do this?

2

it redirects fine, but it shows the numerical IP address and not the subdomain name.

It's not a "redirect" that you want (at least, not if you want to do this "properly"). You should configure your subdomain as an A record in DNS that points to your "home server's IP address".

You must then configure your home server to accept requests for this subdomain. (Probably through a ServerName or ServerAlias directive in a <VirtualHost> on your home (web) server.)

and they offered a checkbox to forward with masking. Masking works.

I believe Godaddy's "masking" just uses a frame (or iframe) to literally "hide" the target URL from the browser's address bar. This has a number of drawbacks:

  • The URL in the address bar does not change as the user navigates the site. Pages are therefore impossible to bookmark or share.
  • The URL in the frame (ie. the target IP address) is the one that will be crawled by bots. So, the IP address will be indexed, not the subdomain used as the "forward".

This might be OK in some casual situations, but most of the time it's not (for the reasons mentioned above) - it is a last resort.

  • Thanks for the explanation. I will avoid redirects. I have set up an A record with Bluehost and am waiting for it to take effect. In the meantime, I noticed this disclaimer from Bluehost: "Our environment does not support Reverse DNS Lookups. This means that a Reverse DNS Lookup will not resolve to the domain name, but instead to the server that the hosting account is on." Does this mean I can't avoid the display of the IP address of my server in the browser's address bar? – Jeff Matthews Nov 26 '17 at 20:16
  • 1
    Never mind the previous comment. The forwarding took effect, and it works nicely. Thanks! – Jeff Matthews Nov 26 '17 at 21:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.