# domain redirect to another domain subfolder

**URL:** <https://forums.interworx.com/t/domain-redirect-to-another-domain-subfolder/14093>\
**Category:** General Discussion\
**Tags:** domain-redirect, redirect-to-subfolde\
**Created:** [November 17, 2016, 3:10am UTC](https://forums.interworx.com/t/domain-redirect-to-another-domain-subfolder/14093 "2016-11-17T03:10:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![d2d4j](https://forums.interworx.com/user_avatar/forums.interworx.com/d2d4j/32/16_2.png) [@d2d4j](https://forums.interworx.com/u/d2d4j)\
**Post date:** [November 17, 2016, 3:10am UTC](https://forums.interworx.com/t/domain-redirect-to-another-domain-subfolder/14093/1 "2016-11-17T03:10:15Z")

</div>

Hi  
One of our clients asked a question which I thought had been asked on the forums, so I thought I would post here in case it helps someone  
Our client wanted to redirect a domain to another domain subfolder, where both domains are on the same server  
mytest.url needs to goto test.url/subfolder  
Initially I thought domain pointer, but this cannot point to a subfolder  
To do this, and I have not tested it, but cannot see why it would not work, would be to login to the siteworx account of the domain which needs redirecting, create a htaccess if one does not exits, on the redirect, you set / as the folder, and input the correct full url of where to point to, [http://mytest.url/subfolder](http://mytest.url/subfolder), then set the type, permanent, temporary etc…  
save and this should work I believe  
I hope it helps but sorry if I am wrong  
Many thanks  
John

 ![htaccessredirect.png](https://forums.interworx.com/uploads/default/original/1X/d3ce9eba26ebf2cb240c38b48e3bcf67a7e17e8e.png)

 ![addglobalhtaccess.png](https://forums.interworx.com/uploads/default/original/1X/207e02f75750a8abeac5abf38ed15f9af8e487d9.png)

---

<div class="post-metadata">

**Author:** ![mdeinhardt](https://forums.interworx.com/user_avatar/forums.interworx.com/mdeinhardt/32/34_2.png) [@mdeinhardt](https://forums.interworx.com/u/mdeinhardt)\
**Post date:** [November 25, 2016, 3:51am UTC](https://forums.interworx.com/t/domain-redirect-to-another-domain-subfolder/14093/2 "2016-11-25T03:51:06Z")

</div>

Hi John,

I can think of another way, but haven’t testetd it: You could create a subdomain with the same name as the subfolder and then redirect to that subdomain. Then the correct Rewrite would already be in place via the subdomain logic in the vhost\_domain.conf.

Will try it when I find time, might come in handy some day.

Cheers,

Michael

---

<div class="post-metadata">

**Author:** ![d2d4j](https://forums.interworx.com/user_avatar/forums.interworx.com/d2d4j/32/16_2.png) [@d2d4j](https://forums.interworx.com/u/d2d4j)\
**Post date:** [November 25, 2016, 9:02am UTC](https://forums.interworx.com/t/domain-redirect-to-another-domain-subfolder/14093/3 "2016-11-25T09:02:48Z")

</div>

Hi Michael

Wow good idea and sorry, never thought of that but if memory serves, Paul posted a good few years ago for using that method to make mydomain.url/webmail be referenced as webmail.mydomain.url I think

Sorry if I am wrong but kudos to you

Many thanks

John
