Skip to main content
All CollectionsSalesforce How-Tos and Best Practices
How to Create a Change Set to Promote Sandbox items to Production
How to Create a Change Set to Promote Sandbox items to Production
Engineering Swantide avatar
Written by Engineering Swantide
Updated over a year ago

In Salesforce, a change set is a collection of changes you want to move from one organization (usually a sandbox) to another (usually production). Below are the steps to create and deploy a change set from a sandbox to production.

Update Deployment Setting:

In Salesforce, Deployment Settings are typically managed to control which users or profiles have the ability to deploy metadata from a sandbox to a production environment using change sets. Managing deployment settings is crucial for maintaining the integrity and security of your Salesforce production environment.

Steps to Create Deployment Settings:

  1. Login to Salesforce:

    1. Login to your Salesforce instance, preferably as a System Administrator.

  2. Navigate to Deployment Settings

    1. In the Setup menu, enter “Deployment Settings” in the Quick Find box and select “Deployment Setting"

  3. Add Deployment Connection:

    1. Here you will see a list of available sandboxes and environments.

    2. Locate the environment you wish to add and click "Edit" next to it.

  4. Enable Deployment:

    1. Check “Allow Inbound Changes” and save. This will allow you to deploy changes to this environment.

  5. Confirm the Connection:

    1. The other environment (usually a sandbox) will need to confirm the connection. Repeat the same steps as in 4 within the Sandbox Environment in Scope.

    2. Log into the other environment, go to “Deployment Settings”, and you will see an "Outbound Connections" waiting for approval.

    3. Click on the connection name and click “Accept”.

  6. Verify Connection:

    1. After accepting the connection, go back to the originating environment and verify under “Deployment Status” that the connection status is “Connected”.

Remember that the actual deployment of changes in Salesforce is typically done using Change Sets, Package Installations, Metadata API, or other deployment tools, and the Deployment Settings are just a part of controlling and managing the deployment process.

Once the Deployment Settings have been updated, the next step is to create a Change Set from Sandbox.

Creating a Change Set

  1. Login to your Sandbox.

    1. Go to your Salesforce sandbox where you have made the changes.

  2. Navigate to Setup.

    1. Click on “Setup” in the top right corner.

  3. Create Outbound Change Set.

    1. In the Quick Find box, type “Outbound Change Sets”.

    2. Click “Outbound Change Sets”.

    3. Click “New”.

    4. Fill in the “Change Set Name” and optionally, the “Description”.

    5. Click “Save”.

  4. Add Components.

    1. After saving the change set, you will see sections to add different types of components.

    2. Click “Add” next to the component type you want to add.

    3. Select the components you want to include and click “Add To Change Set”.

  5. Add Profiles/Permission Sets (if needed).

    1. You can also add profiles and permission sets, but this is optional and depends on your changes.

    2. Profiles and Permission Sets need to be added separately in a special way to capture all related settings.

  6. Upload.

    1. Once you have added all components, click “Upload”.

    2. Select your production environment as the target and click “Upload”.

    3. This process may take some time, depending on the size of the change set.

Deploying a Change Set

  1. Login to Production.

    1. Once the upload is complete, login to your production Salesforce environment.

  2. Navigate to Setup.

    1. Click on “Setup” in the top right corner.

  3. Access Inbound Change Set

    1. In the Quick Find box, type “Inbound Change Sets”.

    2. Click “Inbound Change Sets”.

  4. Deploy.

    1. You should see the change set you uploaded from your sandbox.

    2. Click on the change set name.

  5. Review the components and click “Deploy” to apply the changes to the production environment.

  6. Monitor Deployment.

    1. The deployment might take some time. Monitor the progress.

    2. Once complete, validate that the changes have been applied correctly

Remember that deploying change sets can impact your production environment, so it’s best practice to do it during non-business hours and to thoroughly test all changes in a sandbox environment before deployment. Additionally, always have a rollback plan in case things do not go as expected after deployment.

Communicate the Change Set to Stakeholders

  1. Create a Change Set

    1. Verify with Stakeholders that all Metadata Components are included

    2. Obtain Sign-off on Change Set

  2. Promote it to Production

    1. Validate first that the Change Set can Deploy

    2. Instead of Clicking "Deploy," Click the "Validate" button

  3. Communicate to Stakeholders when a change will occur

    1. Often time after Business Hours

  4. Promote the Change Set to Production

    1. Click "Deploy" this time

  5. Validate the Changes in Production

    1. After the Change Set is in Production Run some Test Cases

Once Deployed, Check the Following:

Custom Fields:

  • If Deploying Custom Fields, make sure those fields are visible. Go to the Object in Scope > Fields & Relationships, Click on each Custom Field in Scope:

    • Click "Set Field-Level Security"

    • Select which Profiles it should be visible to

Custom Objects:

  • If Deploying a Custom Object, make sure that the Object is searchable or can be added to the User's App via a Tab.

    • Go to Set Up

    • Search Tab

    • Click New

    • Select Object

    • Give it a Tab Style

    • Select the Profile Visibility of the Tab - It can remain as Default On, if every Profile should have access to it. Click Next.

    • Select the Custom Apps that the Tab should belong to.

    • Click "Save"

Other Considerations:

Deployment Settings:

  1. Permissions:

    1. Ensure that users involved have the “Deploy Change Sets” permission if they are to deploy changes.

  2. Profiles and Permission Sets:

    1. It’s crucial to understand and carefully handle profiles and permission sets during deployment as they contain field-level security, object permissions, etc.

  3. Test Classes:

    1. When deploying code, make sure to include necessary test classes and ensure the code coverage is above the organization’s required percentage.

  4. Backup:

    1. Before deploying any significant changes, it’s prudent to take backups of data and metadata, especially in the production environment.

  5. Deployment Windows:

    1. Schedule your deployments during a window where it impacts the least amount of users if things go wrong.

  6. Monitor Deployments:

    1. After the deployment, monitor the system closely to ensure everything works as expected.

    2. Check logs and run tests to verify the success of the deployment.

Did this answer your question?