Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to mask URL redirect with Google Domains

On Google Domains, I own www.example.com. I also have hosting for free at www.university.com/~myname.

I want to be able to forward www.example.com to www.university.com/~myname,

but I want the domain to still show as www.example.com.

I also want

www.example.com/something/something.txt

to forward to

www.university.com/~myname/something/something.txt,

with the URL still showing www.example.com/something/something.txt.

How can I do this?

(I know this question exists, but the settings page is very out of date: How to mask the domain forward from Google domains without Google app)

like image 335
Arya Avatar asked Nov 04 '17 16:11

Arya


People also ask

How do I forward a subdomain in Google domain?

Log in to your Google Domains account and choose the Domains you would like to manage. Then, select the DNS tab on the left sidebar. Scroll down to the Synthetic records section. Select Subdomain Forward in the dropdown on the left side.


Video Answer


1 Answers

This is not possible without having someone standup a webserver that will redirect requests.

Using CNAMEs you can mask www.example.com to www.university.com since this translation is purely based on DNS. The concept of www.university.com/~myname is an HTTP concept of URL paths and you need an HTTP server (aka webserver) to do this redirection.

Look at URL forwarding services (NameCheap offers such a service https://www.namecheap.com/support/knowledgebase/article.aspx/545/51/how-do-i-set-up-url-redirect-when-i-use-your-freedns-service when you use their FreeDNS servers for your DNS). You don't need to move your domain registration to them (you can keep that with Google), just move your NS records to namecheap servers to use their redirection service.

like image 195
proteus Avatar answered Sep 21 '22 15:09

proteus