You are here:
Moving Messaging Data Between Sandbox and Production
Learn best practices for moving Messaging channels, data, and configurations such as messaging components between sandbox and production orgs. This article applies to sandbox-to-sandbox, sandbox-to-production, and production-to-production moves.
Required Editions
| View supported editions. | |
This article applies to:
|
Enhanced WhatsApp, Enhanced Facebook Messenger, Enhanced SMS, Enhanced Apple Messages for Business, and Enhanced LINE channels |
This article doesn’t apply to:
|
Enhanced In-App Chat, Enhanced Web Chat v1, Enhanced Web Chat v2, Bring Your Own Channel, Standard Facebook Messenger, and Standard SMS channels |
What’s Supported in Org-to-Org Moves
To get started, review the types of Messaging data that you can move between orgs and the method for moving each type. Change sets can be used if you’re moving data between orgs that are tied to the same production org—for example, between a sandbox and its production org. Managed packages don’t have this restriction, and can be used to move data to any org.
| Type of Data | Can Move Between Orgs? |
|---|---|
| Messaging components | Yes. Use a change set, managed package, or Metadata API. If you added translations of a messaging component in Translation Workbench, include the translations in your change set or managed package. If you use Metadata API to move a Notification messaging component, the component’s association with a WABA ID is lost and must be reestablished in the destination org. |
| Omni-Channel flows and routing configurations | Yes. Use a change set or managed package. |
| Custom report types | Yes. Use a change set or managed package. |
| Apex triggers and workflow rules | Yes. Use a change set or managed package. |
| Sensitive data rules | No. Recreate your rules in the destination org. |
| Enhanced Apple Messages for Business channel | Yes. Can be completed in Salesforce Setup and Apple account settings with little to no downtime. Use the Metadata API for the migration of metadata from sandbox to production and vice versa. |
| Enhanced Facebook Messenger channel | Yes. Can be completed in Salesforce Setup and Facebook account settings with little to no downtime. |
| Enhanced LINE channel | Yes. Can be completed in Salesforce Setup and LINE account settings with little to no downtime. |
| Enhanced SMS channels (long code, toll-free long code, short code) | Yes. Requires a Salesforce Customer Support case to activate the channel in the destination org. Moving an SMS channel from production to sandbox isn’t supported. Use the Metadata API for the migration of metadata from sandbox to production and vice versa. |
| Enhanced WhatsApp channel | Yes. Can be completed in Salesforce Setup and WhatsApp account settings with little to no downtime. Use the Metadata API for the migration of metadata from sandbox to production and vice versa. |
Best Practices for Moving Messaging Data
- Test your Messaging channel settings and routing in a sandbox. Doing so helps you find and address issues with your routing and user experience before you go live in production. It also reduces the need for moving data or channels between orgs.
- If it’s possible, use a separate number or account for testing. For example, create a test Facebook page, an internal test Apple Messages for Business account, or a test WhatsApp account. For SMS channels, Salesforce can provision trial long code and toll-free long code numbers, but not trial short codes.
- Establish the channels that you want in production, even if they remain deactivated. If you refresh your sandbox, those channels are copied to your sandbox and can save you reconfiguration time.
Before Refreshing a Sandbox
By default, Messaging is disabled in sandboxes. When you refresh a sandbox where Messaging was enabled, several things happen in the sandbox:
- Messaging is disabled.
- The sandbox org ID is updated.
- All messaging sessions and messaging user records in the sandbox are deleted. If the sandbox contained any messaging channels that didn’t also exist in production, those channels are also deleted. Re-enabling Messaging doesn’t restore this data.
- If you re-enable Messaging in the sandbox, all messaging channels and messaging components are copied from production in a deactivated state.
To avoid issues, disable all Messaging channels in your sandbox before refreshing it.
Moving Active Messaging Channels
The way you move an active Messaging channel from one Salesforce org to another depends on the type of channel.
In enhanced Facebook Messenger, WhatsApp, Apple Messages for Business, and LINE channels, you can maintain the same channel in both a sandbox and its production org. However, the channel can’t be active in two orgs at once.
Moving an enhanced channel involves little to no downtime. In channels other than SMS, you’ll deactivate the channel in the first org (the “source org”) and activate it in the second org (the “destination org”). If the destination org doesn’t already include a copy of the channel, you’ll use the New Channel setup flow to recreate the channel before activating it. During the time between deactivation and reactivation, messages don’t flow to and from Salesforce in the channel, including auto-responses. However, customers can still send you messages. In SMS channels, Salesforce Customer Support must enable channels for you.
If you try to activate a channel that’s still active in another org, the activation fails. If this happens:
- Deactivate the channel in the first org, and try again.
- If you don’t have access to the first org—for example, if it’s a sandbox that no longer exists—file a case with Salesforce Customer Support to deactivate it.
Moving an Enhanced Apple Messages for Business Channel
Step 1: In the source org, deactivate the original channel.
Step 2: Optionally, use the methods listed in the table above to copy messaging components or other configurations to your destination org.
Step 3: If the destination org already contains a deactivated copy of your channel, activate the channel there. If it doesn’t, or if you want to change your destination org channel to use a commercial Apple Messages account instead of an internal testing account, use the New Channel setup flow on the Messaging Settings page to recreate and activate your channel.
Moving an Enhanced Facebook Messenger Channel
Step 1: In the source org, deactivate the original channel.
Step 2: Optionally, use the methods listed in the table above to copy messaging components or other configurations to your destination org.
Step 3: If your destination org already contains a deactivated copy of your channel, activate the channel there. If it doesn’t, move the page to your destination org:
- Log in to Facebook and go to the Facebook page that you want to migrate.
- Select Settings, then select Advanced Messaging. Under Connected Apps, select Remove next to the Salesforce Service Cloud listing.
- In the destination org, go to the Messaging Settings page in Setup.
- Click New Channel and recreate your channel, selecting the Facebook page when prompted. Then, activate your channel.
Moving an Enhanced LINE Channel
Step 1: In the source org, deactivate the original channel.
Step 2: Optionally, use the methods listed in the table above to copy messaging components or other configurations to your destination org.
Step 3: If your destination org already contains a deactivated copy of your channel, go to the next step. If it doesn’t, use the New Channel setup flow on the Messaging Settings page to recreate the channel.
Step 4: In the destination org, go to the Messaging Settings page in Setup.
Step 5: Click your channel’s name to open the channel record home page. There, find the Webhook URL field and copy the field value.
Step 6: In the LINE Developers Console, go to the Messaging API tab of your channel and paste the value into the Webhook URL field. Then, click Verify.
Step 7: In the destination org, return to the channel record home page and activate your channel.
Moving an Enhanced SMS Channel
For more information on how to move an Enhanced SMS channel metadata to sandbox , see Move Enhanced SMS Channel Metadata to Sandbox
In enhanced SMS channels, you can move a channel from sandbox to sandbox or sandbox to production. In both scenarios, you must file a case to activate the channel in the destination org. These steps apply for enhanced long code, toll-free long code, and short code channels.
Step 1: Optionally, use the methods listed in the table above to copy messaging components or other configurations to your destination org.
Step 2: File a case with Salesforce Customer Support to activate the new channel.
Moving an Enhanced WhatsApp Channel
Step 1: In the source org, deactivate the original channel.
Step 2: Optionally, use the methods listed in the table above to copy messaging components or other configurations to your destination org.
Step 3: If the destination org already contains a deactivated copy of your channel, activate the channel there. If it doesn’t, use the New Channel setup flow on the Messaging Settings page to recreate and activate your channel.



