Mobile app version of vmapp.org
Login or Join
Sue5673885

: Domain, subdomain and path forwarding I have four domains: domain.in domain.com domain.org domain.co.in I want to make domain.in as my main domain. I want to forward all my other domains to it.

@Sue5673885

Posted in: #Dns #DomainForwarding #Domains #Redirects #Subdomain

I have four domains:

domain.in
domain.com
domain.org
domain.co.in


I want to make domain.in as my main domain. I want to forward all my other domains to it. I want to set up forwarding such that:


domain.com goes to domain.in domain.com goes to domain.in xyz.domain.com goes to xyz.domain.in
abc.domain.com/path/to/directory goes to abc.domain.in/path/to/directory


How can I do that?

Screenshot of my registrar's domain forwarding form

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Sue5673885

2 Comments

Sorted by latest first Latest Oldest Best

 

@Ann8826881

<meta http-equiv="refresh" content="0;URL=http://www.theothersite.com">


If you don't fancy rewriting anything, just pop that into a web-page and Bob's your uncle.

10% popularity Vote Up Vote Down


 

@Eichhorn148

You won't be able to do that with the options that your registrar give you. You will have to point your domains to your web host (probably with wildcard DNS) and do it yourself.

Here is a rewrite rule that you can put in your .htaccess file that will redirect any subdomain and path of domain.com, domain.org, or domain.co.in to the corresponding subdomain and path of domain.in

RewriteCond %{HTTP_HOST} ^(.*)domain.(com|org|(co.in))$ [NC]
RewriteRule ^(.*) %1domain.in/ [L,R=301]

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme