Multiple Domain for Single WordPress Installation

I’ve 2 domains ( & and wanted to point those 2 to the same single wordpress installation. Here’s what I did.

1. Point both domains to same public IP at DNS A record.
2. Just add these 2 lines into wp-config.php

define('WP_SITEURL', 'http://' . $_SERVER['HTTP_HOST']);
define('WP_HOME', 'http://' . $_SERVER['HTTP_HOST']);

That’s all =)

Leave a Reply

Your email address will not be published. Required fields are marked *

Proudly powered by WordPress | Theme: Baskerville 2 by Anders Noren.

Up ↑