How to integrate Azure Blob storage with CloudFiles
Here's a step-by-step guide to help you connect your Azure blob storage container with CloudFiles.
- Search for CloudFiles in Microsoft Entra Gallery.
- Click on CloudFiles and click "Create" to add an instance of CloudFiles application in your Azure portal

If the above doesn't work for you, alternatively you can click the button below to authorize CloudFiles. This will add CloudFiles automatically to your enterprise applications list.
- Navigate to Azure Portal - Log in to your Azure portal.
- Create a New Storage Account - Go to the 'Storage accounts' section and click on 'Add' to create a new storage account.
- Configure the Storage Account - Follow the on-screen instructions to configure your storage account, selecting the appropriate subscription, resource group, and other relevant settings.
- Open Storage Account - Once the storage account is created, open it.
- Create Container - In the storage account dashboard, locate the 'Containers' section and create a new container. Assign a name and set the access to Private (no anonymous access)
Enable Storage Account Key Access - In the storage account settings, go to Configuration. Ensure Allow storage account key access is enabled, which is essential for CloudFiles integration.

Update CORS settings - In the storage account settings, go to Resource Sharing (CORS). Add CORS rules to allow GET/PUT methods. For the origin, enter your Salesforce domain and https://salesforce.cloudfiles.io. Ensure you include both sandbox and production URLs, depending on where the account will be used. CloudFiles URL is required to view files inside salesforce
Allowed origin | Allowed methods | Allowed headers |
---|---|---|
<your salesforce domain>(https://cloudfiles.lightning.force.com) | GET, PUT | * |
https://salesforce.cloudfiles.io | GET,PUT | * |
 |  |  |
Make sure to NOT include /at the end of the URL
Add Storage Blob Delegator Permission - In the storage account settings, go to Access Control (IAM). Create a new Role Assignment. Select the role: "Storage Blob Delegator". On Members screen, search for "CloudFiles" service principal.
Add Storage Blob Data Contributor Permission - In the container settings, go to Access Control (IAM). Create a new Role Assignment. Select the role: "Storage Blob Data Contributor". On Members screen, search for "CloudFiles" service principal.
Open CloudFiles Setup in Salesforce - Log into your Salesforce account and navigate to the CloudFiles app launcher. Go to libraries section in Document Management app, select Azure Blob and click on Connect


Add the following URL to trusted URLs in Salesforce:
https://{storageAccountName}.blob.core.windows.net
For example, if storage account name is cloudfiles , URL will be: https://cloudfiles.blob.core.windows.net
Make sure to enable connect-src and img-src option in the trusted url:
