Multi-Site Management
A single dotCMS instance can manage multiple websites simultaneously. Each site is a separate website with its own content, folder structure, templates, and permissions — but all sites are served from the same dotCMS server. A single instance can manage hundreds of sites.
How Sites Work#
On the front end, sites are distinguished by domain name. Each domain is mapped via DNS to the IP address of the dotCMS server. When dotCMS receives a request, it automatically serves content from the site mapped to the requesting domain.
On the back end, you can switch between sites using the Change Site menu in the top-right corner of any content-related page. You can select a site from the list or search by typing the first three letters of the site name into the popup field.
The Host Content Type#
All sites are instances of the Host Content Type. You can edit this Content Type from the Content Types tab to add custom fields — for example, API keys, mobile redirect URLs, or other site-specific metadata. Any fields you add will be available to edit on each site and can be pulled dynamically on front-end pages.
The Default Site#
You should create an empty site with no content and designate it as the default site. The default site is served when dotCMS cannot match the incoming domain to any known site hostname or alias — for example, when the server is accessed via localhost or directly by IP address.
Setting a blank default site is a security best practice: it ensures that only explicitly configured domains can expose site content.
Note: The default site cannot be archived. To archive a site, first assign a different site as the default.
The System Host#
The System Host is a global content store accessible from all sites on the same dotCMS instance. Content stored on the System Host can be accessed and shared across all your sites.
When creating content that allows you to specify a host or folder, you may assign it to a specific host, a specific folder on a host, or the System Host. Content on a specific host is only accessible to users and roles with access to that host. Content on the System Host is available to all users with appropriate permissions, regardless of which host they're accessing it from.
System Host Limitations#
Not all content types can be stored or shared via the System Host:
- Only content items whose Content Type includes a Site or Folder field can be assigned to the System Host.
- The following content types cannot be created on the System Host, even if their Content Type has a Site or Folder field:
- Files (File Assets, Images, Documents, etc.)
- Pages
- Menu Links
- Vanity URLs
- Templates and Containers
If you need to share content of these types across sites, consider creating a dedicated shared-content host on your instance, and set permissions so that users from other hosts can access it.
Managing Sites#
To manage sites, navigate to Settings → Sites.
The Sites list displays each site's Site Key (its name) and any configured Aliases. To filter the list, type into the keyword search box — only sites whose host name or alias matches will be shown.
- Left-click a site name to edit its properties.
- Right-click a site name to access additional actions.
Right-Click Actions#
| Action | Description | Available When |
|---|---|---|
| Edit | View and edit site properties | Not Archived |
| Edit Site Variables | Add site variables to this site only | Not Archived |
| Stop Site | Deactivate the site so it is no longer publicly accessible | Active |
| Start Site | Reactivate a stopped site | Inactive and Not Archived |
| Archive Site | Archive the site, removing it from the active and inactive lists | Inactive and Not Archived |
| Unarchive Site | Restore a previously archived site | Archived |
| Delete Site | Permanently delete the site and all its contents — this cannot be undone | Archived |
| Make Default | Set this site as the default site | Not Archived |
| Add To Bundle | Add the site to a Push Publishing bundle | Always |
Adding a Site#
Click the + Add Site button in the Sites list. You will be prompted to choose between:
- Copy an existing site — copies selected objects from another site into the new one
- Start with a blank site — creates an empty site from scratch
Copying a Site#
Select Copy an existing site and click Next. Choose the source site from the dropdown, then use the checkboxes to select which object types to copy (templates, containers, pages, etc.). Click Next to open the site properties editor, pre-filled with the copied site's properties — edit as needed before saving.
Site Properties#
Whether creating a blank site or copying an existing one, you will edit the same set of properties:
| Field | Purpose | Description |
|---|---|---|
| Host Name | Identifier | A name used to reference the site within dotCMS. Important: This is an identifier and should not be changed once you have begun creating content. It is recommended that this not match your public domain — use the Aliases field for that instead. The host name must be a single word; hyphens and periods are permitted. |
| Aliases | DNS Mapping | All domains that should route to this site. Each alias must be separated by a line break (Shift+Enter to insert a line break). |
| Tag Storage | Tag Sharing | Sets the Tag Repository used by this site. |
| Host Thumbnail | Display | A logo or thumbnail image, pullable dynamically on front-end pages. |
| Run Dashboard | Option | Enables or disables dashboard statistics for this site. |
| Keywords | Metadata | Keyword metadata for the site. |
| Description | Metadata | Description metadata for the site. |
| Mobile URL | Mobile Redirect | A mobile site redirect URL, if needed. |
| Google Map | Site Key | The site's Google Maps API key, if any. |
| Google Analytics | Site Key | The site's Google Analytics key, if any. |
| Add This | Site Key | The site's AddThis key, if needed. |
| Other | Custom Fields | Any additional fields added to the Host Content Type will also appear here. |
The first five fields are required for all sites. The remaining fields are optional examples — you can remove any of them or add your own by editing the Host Content Type. Fields that can be removed are indicated by a trash icon in the Content Type editor.
Saving and Activating#
- Clicking Save saves a draft of the site that is not publicly accessible, regardless of permissions.
- Clicking Save/Activate publishes the site and makes it publicly accessible where permissions allow.
Site Lifecycle#
Sites in dotCMS follow a defined lifecycle: Active → Stopped → Archived → Deleted. Each transition requires the previous step to be completed first.
Deactivating a Site#
To take a site offline without deleting it, right-click the site in the Sites list and choose Stop Site. The site will no longer be publicly accessible, but its content is preserved.
Archiving a Site#
To remove a stopped site from your active sites list, right-click it and choose Archive Site. The site will no longer appear in the default Sites list view.
The default site cannot be archived. You must assign a different default site before archiving.
Deleting a Site#
Deletion is permanent and cannot be undone.** All content within the site — subfolders, files, pages, menu links, content types, templates, containers, and more — will be permanently deleted.
To delete an archived site:
- In the Sites list, check the Show Archived checkbox. Archived site names appear in red.
- Right-click the archived site and choose Delete Site.
- Confirm the deletion when prompted.
Testing with a Local Hosts File#
During development, you may not have DNS records configured for your dotCMS sites. You can simulate DNS resolution locally by editing your machine's hosts file:
- macOS / Linux:
/etc/hosts - Windows:
C:\Windows\System32\drivers\etc\hosts
Add entries mapping your site hostnames to your dotCMS server's IP address. Note that dotCMS does not support assigning a separate default site per IP address — default site resolution is global to the instance.