Upgrading an instance
Use npm run upgrade to refresh an existing vanityURLs instance. The command updates the product-owned files and leaves your instance-owned files alone.
Run it from a clean worktree:
npm run upgrade
The command fetches the configured upstream source, refreshes product files such as defaults/ and scripts/, runs the project checks, and leaves a normal Git diff for review. If package dependency definitions changed during the refresh, the upgrade runs npm install before validation so local tooling matches the updated product files.
Defaults are inherited
defaults/v8s-site-config.json with custom/v8s-site-config.json, so missing additive fields inherit the product baseline. Rerun npm run setup only when you want to change instance-owned answers.What stays yours
The upgrade workflow does not replace:
custom/wrangler.toml.dev.vars- Cloudflare secrets
- generated
build/output
That keeps your links, branding, policies, legal pages, Access configuration, analytics settings, and deployment shape under your control.
Review and publish
After the command finishes:
git status --short
git diff
npm run check
git add defaults scripts package.json package-lock.json .npmrc .prettierignore
git commit -m "chore: upgrade vanityurls runtime"
git push
If the command stops, read the error and inspect git status --short before retrying. If you are migrating an older Cloudflare Pages _redirects instance to the Worker runtime, read Migrating from Cloudflare Pages redirects to vanityURLs Workers first.