# Multisite Integration

Domain Mapping System fully supports [multisite networks](https://wordpress.org/support/article/create-a-network/).&#x20;

To get started with Domain Mapping System on a multisite, install the free plugin on your Network Admin > Plugins page. Then, click "Network Activate," as seen in this screenshot:

![Clicking Network Activate on the Domain Mapping System Plugin](/files/2wIxMKx26NcaLYzjiGNW)

After activating the plugin on your multisite network, go to any of your network sites, and click Domain Mapping on the WP-Admin menu bar.&#x20;

You'll notice the following notification at the top of the settings area, which covers two steps you need to take to activate Domain Mapping System on a multisite network:

![Notification to Configure the Multisite Network Settings](/files/2fRQj5ULL7BNpGVRemLg)

{% hint style="warning" %}
It looks like you are using a Multisite Network. To enable Domain Mapping System for multisite, add the following string to your **`wp-config.php`** file in **`/home/712913.cloudwaysapps.com/vwnnjkafun/public_html/`** above the line reading **`/* That's all, stop editing! Happy publishing. */`**.\
\
`define( 'SUNRISE', true);`\
\
You must also copy and paste the sunrise.php file from **`/home/712913.cloudwaysapps.com/vwnnjkafun/public_html/wp-content/plugins/domain-mapping-system/`** to the directory **`/home/712913.cloudwaysapps.com/vwnnjkafun/public_html/wp-content`**
{% endhint %}

### Modify wp-config.php File

The first step is to modify your `wp-config.php` file, which is typically located in the `public_html` directory of your hosting server (or your corresponding root public directory, which may go by a different name).&#x20;

To modify this file, you'll need access to your server's File Manager or FTP/SFTP connection. Contact your hosting company to get access to modify the files if you don't already have it.

Once you've got the file open, scroll to the bottom, near the line `/* That's all, stop editing! Happy publishing. */`

Then, add the following line directly above that:

```
define( 'SUNRISE', true);
```

It should look something like this:

![Adding the line define( 'SUNRISE', true); to the wp-config.php file](/files/lYkXOxYIJ6fjNvlhDkOt)

Ensure you've saved the file, and move on to step two.&#x20;

### Move the sunrise.php File into wp-content Directory

The second step is to move the provided sunrise.php file into your wp-content directory. The plugin includes a file called sunrise.php in the main plugin directory. Now that you've installed the plugin, navigate to the directory `public_html/wp-content/plugins/domain-mapping-system/` in your File Manager or FTP/SFTP browser.

Duplicate the `sunrise.php` file found in the plugin directory.&#x20;

Then, move the duplicated file to the `wp-content` directory.&#x20;

The duplicated file will have been automatically renamed, so change the name back to `sunrise.php`.&#x20;

Your `wp-content` directory should look something like this:

![Sunrise.php Files in the wp-content Directory](/files/iJOGWaMnwCoNwtZUmgDa)

The reason for keeping the original in place is in case anything ever happens to the duplicated file - you'll easily be able to replace it with the latest version.&#x20;

Here's how it looks only in the wp-content directory (closed).&#x20;

![sunrise.php File in the wp-content Directory](/files/sMgAWJp9mCDUSsUUorm9)

Once you've completed the two steps above, go back to your WP-Admin Dashboard and refresh the page.&#x20;

When the plugin detects the proper configuration, the notification will disappear.&#x20;

Feel free to switch between your sites and map domains!&#x20;

{% hint style="warning" %}
Ensure every mapped domain has been configured properly by following our [Quick Setup](https://docs.domainmappingsystem.com/getting-started/how-to-map-domains) guide.&#x20;
{% endhint %}

{% hint style="success" %}
In the future, we will have more [direct hosting platform integrations](https://docs.domainmappingsystem.com/integrations-and-compatibility/hosting-platform-integrations) so that Administrators on the Network sites will be able to map domains automatically without manual server configuration.
{% endhint %}

{% hint style="info" %}
Please contact us at <support@domainmappingsystem.com> if you get stuck anywhere or have additional questions.&#x20;
{% endhint %}

{% content-ref url="/pages/PVFo2VIyzETEF9WFuDp3" %}
[Hosting Platform Integrations](/domainmappingsystem-docs/integrations-and-compatibility/hosting-platform-integrations.md)
{% endcontent-ref %}

### Alias Domain Authentication Requirements

If you are trying to configure [Alias Domain Authentication](/domainmappingsystem-docs/features/alias-domain-authentication.md) or [Subdomain Authentication](/domainmappingsystem-docs/features/subdomain-authentication.md) on a multisite, you must update the sunrise.php to change this string from this:

```
if ( ! is_multisite() || $is_admin ) {
    return $site;
}
```

To this:

```
if ( ! is_multisite() || ! $is_admin ) {
    return $site;
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://domainmappingsystem.gitbook.io/domainmappingsystem-docs/features/multisite-integration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
