Is it possible to have the same domain across two different servers distinguished by just a folder name.


Server 1 www.domain.com/publicstuff

Server 2 www.domain.com/privatestuff

Other considerations.

  • The servers might not be on the same IP range,
  • The servers might not be in the same physical location
  • The servers will be using different web technologies and hosts
    • Drupal/Apache, Webforms/MVC/IIS
  • 2
    No, it's not. That is not how domain names work. – Jenny D Jul 26 '17 at 14:04
  • I thought not but thought I would ask the wider community. – djack109 Jul 26 '17 at 14:05
  • 1
    @JennyD It's not how domain names work, but that doesn't mean it's not possible. This is something you could set up with AWS Cloudfront, for example, using it's ability to have multiple origins for a single distribution. – ceejayoz Jul 26 '17 at 14:13
  • You are right of course, @ceejayoz - I was wrong to focus only on the DNS side of things. Thanks for correcting me! – Jenny D Jul 26 '17 at 14:15
  • what is the problem you are trying to solve? – aaaaa says reinstate Monica Jul 27 '17 at 20:36

As Jenny said, this is not generally possible. However, you could add a reverse proxy in front of your setup and map two external servers to two directories on your front end domain. Note that this is not necessarily possible for all web apps and might potentially increase latencies.

|improve this answer|||||
  • Thanks All. I said it wasn't a good idea so thanks for the back up – djack109 Jul 26 '17 at 14:15

Of course it possible, CDN-services or large sites can use this way.

Example for nginx:

location /publicstuff/ {
  root /var/www;
location /privatestuff/ {

Users vision: www.domain.com/publicstuff/ and www.domain.com/privatestuff/ are identical, but all queries to privatestuff are proxying to another server.

|improve this answer|||||

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.