Multiple Domain


Multiple Domain allows you having more than one domain in a single WordPress installation. This plugin doesn’t support
more than one theme or advanced customizations for each domain. It’s only intended to enable constant navigation under
many domains. For a more complex setup, there is
WordPress Multisite (MU).

When there is more than one domain set in your host, all links and resources will point to the default domain. This is
the default WordPress behavior. With Multiple Domain installed and properly configured, it’ll update all link on the
fly. This way, the user navigation will be end-to-end under the same domain.

You can also set an optional base URL. If you want only a set of URL’s available under a given domain, you can use this

Additionally, a language can be set for each domain. The language will be used to add <link> tags with hreflang
attribute to document head. This is for SEO purposes.


Follow the steps below to install the plugin:

  1. Upload the plugin files to the /wp-content/plugins/multiple-domain directory, or install the plugin through the
    WordPress plugins screen directly.
  2. Activate the plugin through the ‘Plugins’ screen in WordPress.
  3. Use the Settings -> General screen to configure your additional domains.


Does this plugin set extra domains within my host?

No. You have to set additional domains, DNS, and everything else to use this plugin.

Can I have a different theme/content/plugins for each domain?

Nope. If you want a complex set up like this, you may be interested in WordPress Multisite. It’s delivered with every
WordPress installation since 3.0, you can find more info here: [].

There is a way to add domain based logic to my themes?

Absolutely. You can use the MULTPLE_DOMAIN_DOMAIN constant to get the current domain. Just notice that since this
value is checked against plugin settings, it may not reflect the actual domain in HTTP_HOST element from $_SERVER or
user’s browser. It also may include the host port when it’s different than 80 (default HTTP port) or 443 (default HTTPS

Can I create a custom access restriction logic for each domain?

Yes. You can use the multiple_domain_redirect action to do that. Please check for an example on how to do that.

Can I get the language associated with the current domain?

Yes. You can use the MULTPLE_DOMAIN_DOMAIN_LANG constant to get the language associated with the current domain. Keep
in mind the value in this constant doesn’t necessarily reflect the actual user language or locale. This is just the
language set in the plugin config. Also notice the language may be null.


Very unprofessional

The idea and possibility of this plugin is magnificent. but for a novice user your documentation and installation instructions sucks and lacks serious details.

For instance. do i need to install WordPress on all of the extra domains.?
Do i need to park my extra domains to the mast domains?
Do o need to add them as add on domain to the mast domain?

In addition to all this your website is blank.. I had hoped there might be some more information.

Very unprofessional

Will be seeking alternative methods….

works perfectly

I’m very satisfied with the plugin. Last time when there was an issue with PHP 5.4 compatibility the fix was released almost instantly.

Works exactly as expted – Top Rate

No mess – Just setup the alternative domain name in the general settings after plugin install – Ensure you server and relevant DNS is configured and it just works. Exactly as I expected it to.

Read all 9 reviews

Contributors & Developers

“Multiple Domain” is open source software. The following people have contributed to this plugin.


Translate “Multiple Domain” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.



  • Fix: #23 Undefined index when using wp-cli.


  • Moved MultipleDomain class to its own file.
  • Fix: #14 Remove filter_input from plugin.
  • Attempt to fix #22.
  • Added MULTPLE_DOMAIN_DOMAIN_LANG constant for theme/plugin customization. Fixes #20.
  • Fix: #21 No ‘Access-Control-Allow-Origin’ header is present on the requested resource


  • Make the plugin compatible with PHP 5.4 again.


  • Code review/refactoring.
  • Added activation hook to fix empty settings bug.


  • Fix: #11 Redirect to original domain if SSL/https.


  • Added http/https for alternate link.


  • Fixed resolving host name to boolean.
  • Added Reflang links to head for SEO purpose. E.g.


  • Fixed bug when removing the port from current domain.
  • Added MULTPLE_DOMAIN_ORIGINAL_DOMAIN constant to hold the original WP home domain.
  • Allowing developers to create custom URL restriction logic through multiple_domain_redirect action.
  • Improved settings interface.


  • Improved port verification.
  • Added MULTPLE_DOMAIN_DOMAIN constant for theme/plugin customization.
  • And, last but not least, code refactoring.


This is the first release. It supports setting domains and an optional base URL for each one.