Can one domain be hosted on two drupal instances? I have a huge Drupal 6 site, and a small, newer partial version of the site on Drupal 8. Instead of migrating, we decided to build a brand new site from scratch.

Is it possible to host the site such that:

http://www.sitename.com takes user to --> new D8 site

http://www.sitename.com/topic1 /topic2 takes user to new site.

http://www.sitename.com/topic3 /topic4 (everything else) takes user to old D6 site?

Thanks!
You can use a reverse proxy for this, both Apache and Nginx support this. What you do is that you make the Drupal 6 site available on a different URL. This might be even a local url, like sitename2.local. Add this to the hosts file on your server (/etc/hosts on Linux) and point it to 127.0.0.1. Make sure you set up a virtual host in your webserver to point sitename2.local to the root directory of your Drupal 6 site.

By using a reverse proxy you tell your webservice to forward calls to /topic/4 to sitename2.local/topic/4 and return it to the user, just like a proxy. In Nginx it should look something like:

location /topic/4 {
    proxy_pass http://sitename2.local/topic/4;
}


For Apache you need to enable the proxy modules:

&gt; a2enmod
&gt; proxy proxy_ajp proxy_http rewrite deflate headers proxy_balancer proxy_connect proxy_html


Your virtual host file should look something like this:

&lt;VirtualHost *:*&gt;
    ProxyPreserveHost On

    ProxyPass /topic/4 http://sitename2.local/topic/4
    ProxyPassReverse /topic/4 http://sitename2.local/topic/4
    (...)
&lt;/VirtualHost&gt;


If you Google around for reverse proxy you will find tons of information on how to exactly configure them.