SfSkills Domains Docs GitHub

Home / architect / multi-site-architecture

multi-site-architecture

Use when designing a strategy for multiple Experience Cloud sites within one Salesforce org, selecting a domain and URL pattern, planning shared LWC component libraries, designing cross-site navigation, managing the org's 100-site quota, or deciding between multi-site vs multi-org for portal needs.

Open the skill folder on GitHub


Use this skill when designing or reviewing a strategy for deploying multiple Experience Cloud sites within a single Salesforce org. It covers quota management, domain configuration, shared component architecture, cross-site navigation patterns, license planning, and the decision between multi-site and multi-org. It does not cover single-site setup, deep component development, or unrelated multi-org architecture.


Before Starting

Gather this context before working on anything in this domain:


Core Concepts

The 100-Site Org Limit

Every Salesforce org supports a maximum of 100 Experience Cloud sites. This limit is cumulative across all site statuses:

Salesforce's wording is: "You can have up to 100 Experience Cloud sites in your org. Active, inactive, and preview sites, including Visualforce sites, count against this limit. Archived sites don't count against this limit."

That last sentence is the one that matters operationally. Deactivating does not free a slot, but archiving does — and archiving is reversible, whereas deletion is not. Orgs that have used the site builder repeatedly for demos, proofs of concept and abandoned prototypes accumulate inactive sites that silently consume quota, and the fix is to archive them, not to destroy them.

Practical implication: treat the 100-site limit as a capacity constraint that must be actively monitored. Build a site inventory process. When a site is no longer needed, archive it — that reclaims the quota slot while preserving the site should it be needed again. Reserve permanent deletion for sites you are certain will never be revived.

Domain Strategy and Custom Domains

Every Experience Cloud site has a URL. The structure differs depending on whether a custom domain has been configured.

Default URL pattern (all editions): https://MyDomainName.my.site.com/SiteName

Custom domain pattern (Enterprise+ only): https://portal.company.com/SiteName or https://portal.company.com/

CDN: Experience Builder sites automatically receive CDN caching starting in Winter '19. This applies to Lightning-based Experience Builder sites on custom domains. The CDN caches static assets and page content at edge nodes. No manual CDN configuration is required.

Shared Component Architecture

Experience Cloud sites are separate deployments but they run in the same org and can consume the same Salesforce metadata — including LWC components, Apex classes, permission sets, and custom objects.

What can be shared across sites:

What is site-specific:

Theme layouts are the primary reuse mechanism within a single site — they allow consistent header/footer/navigation across pages of that site. They do not natively span multiple sites. Shared navigation across sites requires explicit linking.

Cross-Site Navigation

There is no native Salesforce feature for automatic cross-portal navigation or session hand-off between Experience Cloud sites. When a user navigates from one site to another:

For orgs using a single IdP for SSO, a user can navigate between sites without re-entering credentials if both sites are configured as Service Providers registered with the same IdP. The user will receive a new SAML assertion for the destination site transparently if the IdP already has an active session.

Without SSO, cross-site navigation drops the user to the target site's login page. Design navigation UI and user journeys to account for this boundary.


Common Patterns

Pattern 1: Audience-Segmented Site Topology

When to use: The org needs separate portals for distinct audience types — for example, a customer self-service portal, a partner deal registration portal, and an employee benefits portal — each requiring different branding, navigation, and access controls.

How it works:

Why not the alternative: Trying to serve multiple audiences in a single site using conditional rendering and permission-based page variants is technically possible but produces unmanageable complexity. Separate sites allow distinct guest profiles, clean URL branding, and independent release cadences.

Pattern 2: Regional Sub-Portal with Shared Component Library

When to use: A global org needs multiple regional sites (EMEA, APAC, AMER) that share branding standards and component logic but require regional customization of language, content, and compliance copy.

How it works:

  1. Build a shared LWC component library targeted for Experience Cloud (isExposed: true).
  2. Use component properties (@api decorated attributes) to externalize configurable content — labels, links, legal disclaimers — so Experience Builder admins can configure each site without code changes.
  3. For translated content, enable Translation Workbench and use the Language Switcher component within each site. The component library does not need to duplicate content per region.
  4. Assign unique SiteName path segments per region (e.g., /emea, /apac, /amer) under the same custom domain base URL, or use separate CNAME subdomains per region.
  5. Maintain a single deployment pipeline that pushes shared LWC components to all sites simultaneously via a Salesforce DX project structure.

Why not the alternative: Forking separate LWC code per site produces drift and doubles (or triples) maintenance overhead. Component property externalization is the correct abstraction point.


Decision Guidance

SituationRecommended ApproachReason
Two audiences (customers and partners) in the same orgTwo separate Experience Cloud sites, one per audience typeClean URL separation, distinct guest profiles, independent release cadence
Multiple regional variants of the same siteOne site per region with shared LWC components and Translation WorkbenchAvoid code duplication; externalize regional content via component properties
Org approaching 100-site limitAudit and archive inactive/unused sites; assess whether preview sites can be mergedActive, inactive, preview and Visualforce sites all consume quota. Archiving frees the slot and is reversible; deletion is not required
Custom-branded URL required (e.g., portal.company.com)Enterprise+ org; configure custom domain in production onlyCustom domain config is not available in sandbox; requires Enterprise edition
Cross-site navigation neededExplicit hyperlinks between site URLs; SSO via external IdP for seamless authNo native cross-portal session sharing; SSO is the only transparent auth hand-off
Requirement appears to need multiple orgs for portal isolationStay in single org with multiple sites unless data residency or regulatory isolation is requiredMulti-org for portal isolation introduces cross-org sync complexity with no benefit
Sandbox testing with custom domainUse default .sandbox.my.site.com URL in sandbox; custom domain testing only in production scratch orgs or UAT using default URLCustom domains cannot be configured in sandbox

Step-by-step instructions for an AI agent or practitioner activating this skill:

  1. Inventory the current org. Count active, preview, and inactive sites in Setup > Digital Experiences > All Sites. Confirm the org edition. Determine how many of the 100-site quota remain. Identify any obsolete or prototype sites that should be archived before the project begins — archiving frees the slot without destroying the configuration.
  2. Define audience segments and site boundaries. For each distinct audience (customers, partners, employees, public), determine whether a separate site is required or whether a single site with permission-based access can serve the need. Document the site topology with audience, license type, URL pattern, and guest vs authenticated access model.
  3. Design the domain strategy. Decide between default my.site.com URLs and custom domains. If custom domains are required, confirm Enterprise+ edition and note that configuration happens in production only. Define the URL path segment naming convention for all planned sites.
  4. Design the shared component library. Identify which LWC components will be reused across sites. Ensure components use @api properties to externalize configurable content. Confirm isExposed: true in each component's .js-meta.xml. Review guest user profile permissions per site — shared components must handle the widest permission set safely.
  5. Design cross-site navigation and user journeys. For each user journey that crosses site boundaries, document the source URL, target URL, and authentication state at the boundary. Determine whether SSO via an external IdP is in scope. If not, design the UX to surface the login context clearly when the user arrives at the destination site.
  6. Validate and document. Run through the Review Checklist below. Record the site topology, domain strategy, and component architecture in the project's architecture decision record. Confirm the license allocation is consistent with the site audience types.

Review Checklist

Run through these before marking work in this area complete:


Salesforce-Specific Gotchas

Non-obvious platform behaviors that cause real production problems:

  1. Preview sites consume the 100-site quota. Teams routinely create preview versions of upcoming site refreshes, accumulate them across multiple projects, and then discover the org is approaching 100 sites. A preview site that is never published still counts until it is archived or deleted. Establish a practice of archiving preview sites when the associated project is closed.
  2. Deactivating a site does not free the quota — archiving does. An inactive (deactivated) site still counts toward the 100-site limit, alongside active and preview sites and Visualforce sites. Archived sites do not count. So the slot-reclaiming action is archive, not delete: it is reversible and it costs nothing. Orgs running Experience Cloud since the Community Cloud era frequently carry double-digit counts of inactive sites that silently consume quota, and the remedy is an archive sweep, not a deletion sweep.
  3. Custom domain configuration cannot be done in sandbox. Teams that try to configure custom domains (Setup > Custom URLs) in a sandbox org will find the option either missing or non-functional. Custom domain configuration must be performed in the production org. Sandbox sites use the default .sandbox.my.site.com URL pattern. Plan UAT and pre-production testing around this constraint.
  4. Cross-site navigation does not transfer the authenticated session. There is no native Salesforce capability that allows a user authenticated in one Experience Cloud site to follow a link and arrive authenticated in another site. Without SSO configured against an external IdP, the user arrives at the destination site's login page. User journeys that cross site boundaries must account for this re-authentication step.
  5. Guest user profiles are per-site and are not inherited from a shared profile. A common mistake is assuming that a permission granted to one site's guest user profile applies to all sites, or that there is a single guest profile to manage. Each site has its own guest user record and guest user profile. Shared LWC components that rely on guest access must be tested against each site's guest profile independently.
  6. License types are not interchangeable across site audiences. A user with a Customer Community license cannot access a Partner Community site. A user with a Partner Community license can access a Customer Community site but consumes a Partner Community license to do so. Mixing license types across audiences in a single site is not the intended design and creates license audit risk.

Output Artifacts

ArtifactDescription
Multi-site topology diagramVisual or tabular map of all planned sites with audience type, URL, license type, and data access scope
Domain strategy documentDefines custom vs default URL pattern per site, environment-specific rules (prod vs sandbox), and DNS/SSL requirements
Shared component inventoryList of LWC components targeted for multi-site reuse with @api property definitions and per-site configuration notes
Cross-site navigation mapUser journeys that cross site boundaries with source URL, target URL, auth state, and SSO dependency
Site quota trackerRunning count of active + preview + inactive + Visualforce sites (archived listed separately, excluded from the quota) with owner, purpose, and planned archive date for obsolete sites
License allocation planLicense type per site audience with user count estimate and cost implications

Package files