Dev Tools · 2h ago
Wrangler dev --remote can silently corrupt production KV data
Cloudflare's Wrangler CLI, when run with --remote, writes to the production KV namespace if the preview_id field is missing from wrangler.toml. The fix is to add a preview_id pointing to a separate dev namespace. Additionally, remote KV is eventually consistent, unlike local simulation, which can hide race conditions.
Meridian48 take
This is a critical developer experience gap that should be addressed in Wrangler's default configuration or documentation, as it can lead to silent data corruption.
Read the full reporting
`wrangler dev --remote` silently writes to your production KV namespace — here's the fix →
DEV Community
cloudflarewrangler-cli