Jump to Content

Firestore adds point-in-time recovery and scheduled backups

September 8, 2023
Malike Stewart

Product Manager, Firestore

Yixiao Shen

Software Engineer, Firestore

We are excited to announce the launch of two new disaster recovery features for Firestore: point-in-time recovery (PITR) and scheduled backups. These features will provide data protection against human errors and disasters. 

This is in addition to Firestore’s automatic and redundant data replication, which allows the service to guarantee up to 99.999% SLA availability with replica failovers demonstrating 0 RPO and 0 RTO.

Point-in-time recovery provides protection against accidental deletion or writes by giving you the ability to version control and query data from the past seven days, and surgically write the needed data back into your database.

Scheduled backups lets you backup your entire database on a chosen frequency of either daily and/or weekly onto cold storage. These backups can be used to restore to a new database in the same project. 

Point-in-time recovery example walkthrough

Let’s say you would like to enable point-in-time recovery. Below you will see how to enable this feature with the Google Cloud console: 

To enable point-in-time recovery, navigate to the “Disaster recovery” page and select the “EDIT” icon.


Select the checkbox for “Enable point-in-time recovery” and click “SAVE”.


The “Disaster recovery” page now includes “Earliest version time” and “Retention period”.


That's it! Point-in-time recovery is enabled and will begin storing data. Please refer to the documentation for more information. 

Scheduled backups example walkthrough

Now we will walk you through how to generate a backup schedule using gcloud commands for both daily and weekly, as well as how to validate that the backups were created. 

To prepare, you’ll want to:

  1. Upgrade gcloud to the newest version

  2. Run `gcloud config set project <project-id>` for the project in which you want to manage backups 

To create a daily backup schedule, use the “backups schedules create” command. Below is an example of daily backup schedule creation:


To create a weekly backup schedule, use the “backups schedules create” command. Below is an example of weekly backup schedule creation:


To validate the backup schedules have been created successfully, use the “backup schedules list” command:


Next steps

For more information on how to set up and configure either of these features, simply check out our documentation for point-in-time recovery and scheduled backups for more information.

Thanks to Minh Nguyen, Senior Product Manager Lead for Firestore, for his contributions to this blog post.

Posted in