Back to blog
Quality
Vercel

How I stop throwaway Vercel demos piling up without manual deletes

Thắng Đoàn
Thắng Đoàn

Demo, prototype, and test deployments linger in your Vercel account and need manual cleanup. Vercel CLI now lets a deploy set the new project to expire so it deletes itself.

What it is

The Vercel CLI supports a --delete-project-after flag on vercel deploy. It schedules automatic deletion of the project after a chosen duration, and vercel project keep can remove an expiration later.

  • Durations supported: 1h, 1d, 1w, 2w, and 30d
  • CLI prints the exact date and time the project expires
  • Flag only applies when vercel deploy creates the project

Applied case

I spin up a demo app for a stakeholder review with vercel deploy and pass --delete-project-after 1d. The project expires and is deleted automatically the next day, so nothing needs cleaning up by hand. If I deploy again to that existing project with the flag, the CLI warns me and leaves the expiration unchanged. Running vercel project keep cancels the expiration if the demo becomes permanent.

  • Deploying to an existing project with the flag triggers a warning, not a change

When to use it

Use when creating prototypes, demos, or test apps you want gone automatically.
Skip when deploying long-lived projects or expecting the flag to update an existing one.

vercel deploy --delete-project-after 1d
vercel project keep

Read more

Vercel CLI project expiration changelog

vercel deploy docs

Share:

Recommended for you

Enjoyed this article?

Subscribe for new articles. No spam. Unsubscribe anytime.

By subscribing you agree to receive the newsletter. No spam, and you can unsubscribe anytime.