How To Restore a Project Paused for More Than 1 Year
Last edited: 8/12/2026
暂停超过一年的项目不能再通过 Supabase Studio 恢复。不过,你仍然可以通过下载可用的备份并将其迁移到新项目来找回数据。
🌐 Projects paused for more than 1 year can no longer be restored through Supabase Studio. You can still recover your data by downloading the available backups and migrating them to a new project.
在删除项目之前,你可以从 Supabase Studio 的 项目概览 部分下载数据库备份和存储对象。
🌐 Both the database backup and Storage objects can be downloaded from the Project Overview section in Supabase Studio before the project is deleted.

看看这个关于完整迁移过程的短视频演示。
🌐 Check this short video walk-through of the full migration process.
步骤 1:下载你的备份 #
🌐 Step 1: Download your backups
在你暂停的项目的项目概览中,下载:
🌐 In the Project Overview of your paused project, download:
- 数据库备份 — 来自备份部分的
.backup文件 - 存储对象 — 来自你存储桶的所有文件
一旦删除项目,所有相关数据包括备份都会被永久移除,不能恢复。
🌐 Once a project is deleted, all associated data including backups is permanently removed and cannot be recovered.
步骤 2:创建一个新的 Supabase 项目 #
🌐 Step 2: Create a new Supabase project
在 database.new 创建一个新项目,并将其配置为与你之前的设置相匹配(扩展、网络钩子、实时发布等)。
🌐 Create a new project at database.new and configure it to match your previous setup (extensions, webhooks, Realtime publications, etc.).
步骤 3:恢复数据库 #
🌐 Step 3: Restore the database
从 连接对话框 获取你新项目的 Session pooler 连接字符串。在连接字符串中将 [YOUR-PASSWORD] 占位符替换为你的数据库密码。如果你不记得密码,可以在 数据库设置 中重置。
🌐 Get the Session pooler connection string for your new project from the Connect dialog. Replace the [YOUR-PASSWORD] placeholder in the connection string with your database password. If you don't remember it, reset it in Database Settings.
如果下载的备份文件是 .gz 后缀,先解压它,然后运行:
🌐 Unzip the downloaded backup file if it has a .gz extension, then run:
1psql -d [CONNECTION_STRING] -f /path/to/backup_file.backup像 object already exists 这样的一些错误是预期内的,可以放心忽略——它们出现是因为新项目已经应用了默认的 Supabase 模式。
🌐 Some errors like object already exists are expected and can be safely ignored — they occur because the new project already has the default Supabase schemas applied.
查看恢复仪表板备份指南以获取详细说明和故障排除方法。
🌐 See the Restore Dashboard backup guide for detailed instructions and troubleshooting.
步骤4:恢复存储对象 #
🌐 Step 4: Restore Storage objects
使用 Supabase CLI 将你下载的存储文件复制到新项目的桶中:
🌐 Use the Supabase CLI to copy your downloaded storage files to the new project's buckets:
1supabase login2supabase link --project-ref [NEW_PROJECT_REF]3supabase storage cp /path/to/downloaded/files ss:///bucket_name -r --experimental对每个桶重复操作。有关所有可用标志,请参见 supabase storage cp 参考。
🌐 Repeat for each bucket. See the supabase storage cp reference for all available flags.
步骤5:复制项目配置 #
🌐 Step 5: Copy project configurations
使用管理 API将配置(身份验证、实时、存储等)从已暂停的项目复制到新项目。你需要在两个项目上都有所有者或管理员权限。
🌐 Use the Management API to copy configurations (Auth, Realtime, Storage, etc.) from the paused project to the new one. You need Owner or Admin permissions on both projects.
从账户令牌页面获取你的访问令牌,然后将下面的脚本保存到一个文件中并使其可执行:
🌐 Get your access token from the Account Tokens page, then save the script below to a file and make it executable:
1chmod +x sync_supabase_config.sh这个脚本会将源配置和目标配置都保存到本地的 config_sync_<timestamp>/ 目录,这样你就可以准确查看都改了些什么。使用 --dry-run 可以在不应用更改的情况下预览差异。
相关指南 #
🌐 Related guides