To restore the data from backup, first download the backup file from Google Cloud Storage and decompress it as per the preceding command. Once you have the JSON file, you can import data in either of the two ways:
- Under the database section of Firebase console, you will find an Import JSON button that will allow you to upload the file.
- You can use a CURL command: curl 'https://<DATABASE_NAME>.firebaseio.com/.json?auth=<SECRET>&print=silent' -x PUT -d @<DATABASE_NAME>.json. Note that you need to replace DATABASE_NAME and SECRET, respectively, with your own values. You can get the secret from the database settings page.