--- title: "Step 6. Configure Retention Settings" description: "At the Retention step of the wizard, you can configure retention settings for the backed-up data — a time period during which Veeam Backup for Salesforce keeps attachments that were deleted from Salesforce and history records." canonical: "https://helpcenter.veeam.com/docs/backup_salesforce/userguide/add_backup_policy_retention.html" breadcrumb: "User Guide > Performing Salesforce Backup > Creating Backup Policies > Step 6. Configure Retention Settings" dateModified: "2026-10-16" --- # Step 6. Configure Retention Settings At the **Retention** step of the wizard, you can configure retention settings for the backed-up data — a time period during which Veeam Backup for Salesforce keeps attachments that were deleted from Salesforce and history records. It allows you to consume less storage space by deleting attachments and history records that are older than the specified time period. Consider the following: - The time period is calculated since creation of a backup of a Salesforce record, not since creation of the record itself. - Veeam Backup for Salesforce will always keep the latest version of a record in the backup even if the specified retention limit is reached and the record has been deleted from Salesforce. To configure retention settings for the backup policy, do the following: 1. In the **Data and attachments retention policy** section: 1. In the **Keep versions for** field, specify the number of days (weeks, months, years) for which you want to keep Salesforce history records and deleted attachments. 2. If you want to configure specific retention settings for different objects protected by the backup policy, click the **Define custom retention policy** link. In the **Custom Retention Settings** window, click **Add Object**, select the necessary object from the **Object** drop-down list, and specify the retention period. Click **Apply**. ::: important Attachments associated with records to which custom retention settings are applied will still be removed according to the main data and attachments retention policy specified in the **Keep versions for** field. ::: 2. The settings specified in the **Data and attachments retention policy** section do not apply to backups of files created by the policy. If you want Veeam Backup for Salesforce to automatically delete these backups according to the retention policy, you must configure their own retention settings in the **Files, Content, Documents** section: - To instruct Veeam Backup for Salesforce to remove backups of files that were permanently deleted from Salesforce according to the retention policy, select the **Purge deleted content older than** check box and specify the period after which these files will be removed. - To instruct Veeam Backup for Salesforce to remove backups of file versions, select the **Purge content versions older than** check box and specify the period after which the outdated versions will be removed. [![Creating Backup Policy](images/add_backup_policy_retention.png "Creating Backup Policy")](images/add_backup_policy_retention.png){.toggle scale=60}