Skip to content

From Vercel KV

Tested with: Generic connection-string flow · zb migrate 0.1 · no Vercel KV (legacy, now Upstash) preset yet

Vercel KV stores run on Upstash Redis. They move to Databasezy Valkey with a key copy, TTLs included.

Vercel KV (legacy, now Upstash) migration at a glance, from the migration source catalogue
Status Coming soon · phase 2
Target engines Valkey
How we read it Connection string
Continuous sync No, copy only
Provider preset None yet (generic)
  • A Databasezy Valkey instance, or use --create.
  • The store’s environment variables, for example with vercel env pull.

Open the store in the Vercel dashboard, or run vercel env pull, and copy KV_URL, the rediss:// URL. The KV_REST_API_URL is an HTTP endpoint and cannot be used for the copy.

  • Vercel KV stores run on Upstash; use the rediss:// URL (KV_URL).

The Upstash guide explains the copy and what changes for REST clients: code that uses @vercel/kv needs a TCP Redis client against Valkey.

  1. Open the target Valkey instance (create one first if you need to) and choose the Migrate in tab.
  2. Under Source, pick Connection string and paste the URL.
  3. Run Preflight and work through the checklist. Blocking items must be fixed before the copy starts.
  4. Start the copy and follow Copy and Verify. Mismatches are listed per table or collection.
  5. Point your application at the new instance. The Report step keeps the timings and verification results.

Verification compares the key count on both sides once the copy finishes. Spot-check a few keys you know, including their TTLs (PTTL <key>), and run your application against the new instance before you switch traffic.

This source is copy only. Writes that reach the source after the copy starts are not carried over, so for a database that changes, stop writes before you start the copy (maintenance mode, or scale writers to zero), run the migration, check verification, then point the application at the Databasezy connection string.

A migration never deletes anything on the source. Until you decommission it, rolling back means pointing the application back at the source. Writes made on Databasezy after you switched are not on the source; if you need them, copy them back before switching. Cancel a running migration with zb migrate cancel <mig_id>; partially restored data stays on the target, so restart with --drop-target or delete the instance.

Check that the source accepts connections from the egress addresses preflight prints, that the host is the public one and that the password has not been rotated. zb migrate --dry-run shows the exact URL that will be used after any rewrites.

Each item has a machine code and a fix. Nothing is written to the target until every blocking item is resolved; warnings do not block.

Fewer keys on the target than on the source

Section titled “Fewer keys on the target than on the source”

Keys that expired during the copy are not restored, and keys written after the copy started may be missed. Compare again after a short write freeze.

For anything else, zb migrate status <mig_id> shows the failing step and its message. How migrations work describes every step.