All Products
Search
Document Center

ApsaraDB RDS:Long-term backup retention

Last Updated:Mar 27, 2026

This topic describes how to retain the backup files of an ApsaraDB RDS for MySQL instance for a long period. Long-term retention helps you restore data when needed and protects your data assets.

Background information

When you use a database, you may encounter the following scenarios:

  • Your data is accidentally deleted, but only backups from the last seven days are available. As a result, you cannot restore older data.

  • Your RDS instance is accidentally released or is released due to an overdue payment. Because the instance has been released for a long time, both your data and backups are unrecoverable.

  • You want to release your RDS instance but retain its backups for future use.

Method 1: Increase the backup retention period

You can increase the number of days that backup files are retained to restore older data when needed.

Note

This operation increases your backup size and may increase your backup storage costs.

  1. Log on to the ApsaraDB RDS console and go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.

  2. In the navigation pane on the left, click Backup and Restoration.

  3. On the Backup and Restoration page, click the Backup Strategy tab. In the Basic backup section, click Edit.

  4. In the dialog box that appears, increase the data backup or log backup retention period. For example, you can change the default value from 7 days to 30 days.

    Note
    • The log backup retention period cannot exceed the data backup retention period.

    • If your instance uses Premium Local SSDs, select Permanently retained before instance release. After you select this option, you do not need to set a data backup retention period. All data backups are retained until the instance is released. For more information, see Automatic backup.

  5. Click OK.

Method 2: Configure the backup retention policy after instance release

Typically, when an RDS instance expires or has an overdue payment, both the instance and its backups are retained for a period of time. After this period elapses, the instance and its backups are released and deleted. To resolve this issue, you can configure a backup retention policy for your RDS instance. Once configured, the RDS instance's backup files are retained for an extended period, even if the RDS instance is unexpectedly released. You can download the backup files from the ApsaraDB RDS console to your computer or restore the backup files to a new RDS instance to prevent data loss. This long-term retention of backup files ensures comprehensive data security.

Limits

This feature is not supported for RDS for MySQL instances that run RDS Enterprise Edition and use Premium Local SSDs.

Billing rules

After your RDS for MySQL instance is deleted, you are charged for backup storage. Backup storage is free for seven days after the instance is released. After seven days, you are charged based on the pay-as-you-go billing method. The unit prices are as follows:

Backup storage pricing for deleted instances with high-performance local disks

Billing site

Storage region

Unit price (USD per GB-day)

Public cloud

China (Hangzhou), China (Beijing), China (Shanghai), China (Shenzhen), China (Qingdao), China (Zhangjiakou), China (Hohhot), China (Chengdu), China (Heyuan), China (Ulanqab), and China (Guangzhou)

0.00058

China (Hong Kong), Singapore, US (Silicon Valley), Germany (Frankfurt), Indonesia (Jakarta), Philippines (Manila), and Thailand (Bangkok)

0.00067

Japan (Tokyo) and South Korea (Seoul)

0.0007

US (Virginia)

0.00062

Malaysia (Kuala Lumpur)

0.00064

UK (London)

0.00065

UAE (Dubai)

0.00072

Unit price for backup storage of deleted RDS for MySQL instances that use cloud disks

Storage region

Unit price (USD per GB-day)

China (Beijing), China (Hohhot), China (Ulanqab), China (Hangzhou), China (Shanghai), China (Shenzhen), China (Heyuan), China (Chengdu), China (Qingdao), China (Guangzhou), and China (Zhangjiakou)

0.0009375

China (Hong Kong), US (Silicon Valley), US (Virginia), Singapore, Japan (Tokyo), Germany (Frankfurt), Malaysia (Kuala Lumpur), Indonesia (Jakarta), Philippines (Manila), UK (London), South Korea (Seoul), and Thailand (Bangkok)

0.001125

Note

You cannot purchase storage plans to offset backup storage fees for deleted RDS for MySQL instances.

Usage notes

  • After an RDS for MySQL instance is released, its retained backup files may take up to 30 minutes to appear on the Backups > Backup for Deleted Instances page.

  • If your account has an overdue payment for more than 30 consecutive days, Alibaba Cloud terminates the backup retention service for the deleted instance and permanently deletes the associated backups.

Procedure

Important
  • For an RDS for MySQL cloud disk instance purchased on or after February 1, 2024, the default backup retention policy for a released instance is Latest.

    Storage is free for 7 days after the instance is released. After 7 days, you are charged for backup storage. To avoid these fees, set the backup retention policy to None.

  • For a new RDS for MySQL instance that uses Premium Local SSDs, the default backup retention policy for a released instance is Do Not Retain.

Select a configuration method based on the current state of your instance.

Method 1: During instance purchase

This method applies only to new subscription RDS for MySQL instances that use Premium Local SSDs. You can set the Backup Retention After Release policy on the purchase page.

image

Method 2: Before instance release

  1. Log on to the ApsaraDB RDS console and go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the instance ID.

  2. In the navigation pane on the left, click Backup and Restoration.

  3. On the Backup and Restoration page, click the Backup Strategy tab. Then, click Edit in the Basic Backup section.

  4. In the dialog box that appears, set Retain Backup Files After Instance Release and click OK.

    • Latest or All (recommended): After the instance is released, the completed backups are retained based on your selection.

    • None: After the instance is released, no backups are retained. Data cannot be recovered. Exercise caution when you select this option.

    Important
    • After the instance is released, the system retains the backup files indefinitely based on the configured policy. You cannot specify a retention period.

    • Retained backup files are stored free of charge for 7 days. After 7 days, you are charged. For more information about the pricing, see Billing.

    • For information about how to use backup files that are retained after an instance is released, see Use backup files from a released instance.

Method 3: After instance release

  1. Log on to the ApsaraDB RDS console. In the left-side navigation pane, click Backups. In the top navigation bar, select the region in which the RDS instance resides.

  2. On the Backup for Deleted Instances tab, find the target instance and click Settings in the Retention Policy column.

  3. In the dialog box that appears, set the Data Backup Retention Policy and click OK.

    • Latest or All (recommended): After the instance is released, the completed backups are retained based on your selection.

    • None: After the instance is released, no backups are retained. Data cannot be recovered. Exercise caution when you select this option.

    Important
    • After the instance is released, the system retains the backup files indefinitely based on the configured policy. You cannot specify a retention period.

    • Retained backup files are stored free of charge for 7 days. After 7 days, you are charged. For more information about the pricing, see Billing.

    • For information about how to use backup files that are retained after an instance is released, see Use backup files from a released instance.

Method 3: Download a backup

You can also download backups to your local machine or to an Elastic Compute Service (ECS) instance for long-term storage. For more information, see Download backups.

FAQ

What is the backup retention policy for released instances and how do I use it?

The backup retention policy for released RDS for MySQL instances is a key feature that helps you protect and recover data. After you enable this feature, you can retrieve important data from the Backups page in the RDS console even if an RDS for MySQL instance is accidentally or manually released. You can then download the backups to a local device or restore them to a new RDS for MySQL instance.

My RDS for MySQL instance has been released. Why am I still being charged for backups?

Your RDS for MySQL instance has been released. However, if you enabled the backup retention policy for released instances before you released the instance, the backup files are retained on the Backups page in the RDS console. Backup storage is free of charge for seven days after the instance is released. After this period, you are charged for the storage.

Backup storage costs are incurred if the retention period exceeds the free 7-day period. These costs are based on the actual storage amount and the region. For more information about the pricing, see Billing. If you no longer need the backups, you can go to the Backup for Deleted Instances tab and set the retention policy for the target instance to Do Not Retain. This prevents future backup storage costs.

I never configured a backup retention policy for released RDS for MySQL instances. Why am I being billed for this feature after my instance was released?

For an RDS for MySQL cloud disk instance purchased on or after February 1, 2024, the backup retention policy for the released instance is set to Latest by default. This policy is applied when the instance is created. Therefore, the system automatically retains the last backup of the instance after it is released. You are charged for these backups after the free 7-day retention period expires.

Note

To avoid misunderstandings or unnecessary costs, regularly check the backup policy settings for your instance and adjust them as needed. If you no longer need these backups, you can manually delete the backups of the released instance to save on storage costs.

How do I delete the backup files of a released instance?

If you no longer need the retained backup files and want to avoid backup storage costs, you can delete the backup files of a released instance.

My RDS for MySQL instance has been released. Why are the retained backup sets not yet displayed on the Backups for Deleted Instances page?

After an RDS for MySQL instance is released, its retained backup files may take up to 30 minutes to appear on the Backups > Backup for Deleted Instances page.

I plan to release my RDS for MySQL instance after my business ends, but I want to restore data from backups later. How do I back up my RDS data to prevent data loss?