---
schema_version: "1"
id: b45c7bcc901c2dea13ab80b6c3641a2a37b998803c08b41eebe17f97384ed103
title: Move a My Domain Name to a Different Org
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/domain_name_move.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.domain_name_move.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: f21d363aba86e0a46fe3931a85b8b4cc47903d6df005986e736805b64e241519
description: You can’t use an existing My Domain name in a new org, even if you own the org where that name is currently in use. To make the My Domain name available for a new org, first remove the name from the old org
products:
  - Salesforce Platform
  - Cross Cloud
release: "264"
---
# Move a My Domain Name to a Different Org

You can’t use an existing My Domain name in a new org, even if you own the org where that name is currently in use. To make the My Domain name available for a new org, first remove the name from the old org

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic and Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Group</strong>, <strong>Essentials</strong>, <strong>Professional</strong>, <strong>Enterprise</strong>, <strong>Performance</strong>, <strong>Unlimited</strong>, and<strong> Developer</strong> Editions</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d53661e84">User Permissions Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d53661e84 ">To edit My Domain settings:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d53661e84 ">Customize Application</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d53661e84 ">To define a My Domain name:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d53661e84 ">
              <p>Customize Application</p>
              <p>AND</p>
              <p style="margin-bottom:0;">Modify All Data</p>
            </td>

          </tr>
        </tbody>
      </table>

## When to Move a My Domain

My Domain names are unique with one exception: A production org and its sandboxes can share the same My Domain name. Sandbox host name formats make this possible. For example, the host name format for a production login URL is `MyDomainName.my.salesforce.com`, and the host name format for a sandbox login URL is `MyDomainName--SandboxName.sandbox.my.salesforce.com`. To make sandbox host name prefixes unique, the sandbox name is appended to the My Domain name. When you create or refresh a sandbox, the process uses the My Domain name from the source org and the sandbox name to set that subdomain for the sandbox host names.

Also, when you specify the My Domain name for a Developer Edition org, `-dev-ed` is appended to the string that you enter in the My Domain name field. So if the My Domain name in production is `example`, you can use `example-dev-ed` as the My Domain name in a Developer Edition org.

Moving a My Domain name is necessary only when you want to reuse the subdomain string that includes the My Domain name. For example, when you replace a production org or a Developer Edition org.

## Move a My Domain Name

To minimize the required updates after you move the My Domain name, take these steps in a new org before you configure additional features and before users access the org.

1. In the old org, rename the My Domain.
    
    For the new name, choose a string that you never intend to use as a My Domain name. See [Change Your My Domain Details](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_rename.htm&release=264.0.0&type=5 "If you don’t like your My Domain or circumstances warrant a change, you can rename it. For example, you can change the name when your company’s name or branding changes. In some orgs, the admin can also choose a different domain suffix, enable enhanced domains, and remove instance names from certain My Domain URLs.").
    
    ![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-xcloud-setup-264-0-0-production-enus/6f21df35-9ea0-4f53-ac94-45c3b5dfd5bc/images/icon_note.png)
    
    Note If you can’t access the old org, contact Salesforce Customer Support.
2. After you deploy the new My Domain name, remove the previous My Domain from the old org.
    
    See [Disable or Remove Your Previous My Domain](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_remove_previous.htm&release=264.0.0&type=5 "Each time that you deploy a change to your My Domain, Salesforce redirects requests from your previous My Domain URLs to your current My Domain. Optionally, disable redirections from your previous My Domain. We recommend that you use that option when you test a My Domain change. Or, to use your previous My Domain in a different Salesforce org, remove your previous My Domain.").
    
    The My Domain name that you remove is the name that you want to use in the new org.
3. Wait at least 15 minutes for the changes to take effect.
4. [Log My Domain host name redirections](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_redirections_log.htm&release=264.0.0&type=5 "To reduce disruption, Salesforce redirects multiple host names automatically when you deploy a change to your My Domain. To track blocked and successful redirections for your My Domain host names, enable event logging for these redirections.") in the new org.
    
    The [Hostname Redirects Event Type](https://developer.salesforce.com/docs/atlas.en-us.object_reference.meta/object_reference/sforce_api_objects_eventlogfile_hostnameredirects.htm) captures redirected calls to the org’s previous My Domain host names.
    
    1. To collect host name redirection logs for multiple days, schedule a daily query of the Hostname Redirects event type via REST API.
        
        For example, you can configure a cron job in Unix or a scheduled task in Windows to run the query.
5. In the new org, update the My Domain name.
    
    See [Change Your My Domain Details](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_rename.htm&release=264.0.0&type=5 "If you don’t like your My Domain or circumstances warrant a change, you can rename it. For example, you can change the name when your company’s name or branding changes. In some orgs, the admin can also choose a different domain suffix, enable enhanced domains, and remove instance names from certain My Domain URLs.").
6. If users accessed the new org or if you configured features in the new org before you moved the new My Domain name, update references to your old My Domain name and URLs.

#### See Also

- [My Domain](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_overview.htm&release=264.0.0&type=5 "Showcase your company’s brand with a customer-specific subdomain name in your Salesforce org URLs. With My Domain, you can include your company name in your URLs, for example, https://mycompany.my.salesforce.com. With these org-specific URLs, you can set up a custom login page, set a custom login policy, offer single sign-on, and allow users to log in with a social account. My Domain also allows you to work in multiple Salesforce orgs in the same browser at the same time.")
- [Plan for a My Domain Change](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_plan.htm&release=264.0.0&type=5 "Whether you change your My Domain to update your brand, to adopt enhanced domains, or to enable partitioned domains, the URLs that Salesforce hosts for your org change. Those changes can have a large impact, and making the required updates can seem like a daunting project. To make the process as smooth as possible for you, your users, and your customers, review the high-level steps, the recommended practices, and how to reduce the impact on your users and customers.")
- [Update Your Org for My Domain Changes](https://help.salesforce.com/s/articleView?id=xcloud.domain_name_guidelines.htm&release=264.0.0&type=5 "When you deploy a change your My Domain, your Salesforce org’s login URL and application URLs change. URLs that are dynamically constructed—for example, URLs generated via the DomainCreator Apex class—use the new URLs automatically. However, some Salesforce functionality requires an update to work with your new URLs. Similarly, custom code, your network configuration, and third-party integrations that use the old URLs require updates. To ensure a smooth transition to your new URLs, update references to your old URLs.")