- 01.Starting Point
- 02.Listing Blobs
- 03.Counting the Damage
- 04.Batch Deletion
- 05.Where We Landed
- 06.Takeaways
Vercel Blob Storage Cleanup
Free Vercel blob storage quota was being consumed, but unclear which project was responsible. The blob store was named \"slay-the-spire\" and the user had the read-write token handy.
Starting Point
Free Vercel blob storage quota was being consumed, but unclear which project was responsible. The blob store was named "slay-the-spire" and the user had the read-write token handy.
Listing Blobs
The --rw-token flag didn't work as expected:
vercel blob list --rw-token vercel_blob_rw_qS3fAZ1vOkRldVEZ_Ul4bepvh8rGZN5vtVKs5vldOHEfqYi --limit 20Error: No Vercel Blob token found.
The env var approach works instead:
BLOB_READ_WRITE_TOKEN=vercel_blob_rw_qS3fAZ1vOkRldVEZ_Ul4bepvh8rGZN5vtVKs5vldOHEfqYi vercel blob list --limit 20This listed PNGs — all game screenshots, ~1.5-2.4 MB each, uploaded ~270 days prior.
Counting the Damage
BLOB_READ_WRITE_TOKEN=... vercel blob list --limit 1000 2>&1 | grep -c "\.png"760 PNGs — roughly 1.5 GB of screenshots eating the free tier.
Batch Deletion
Extracted all URLs to a file:
vercel blob list --limit 1000 2>&1 | grep "https://" | awk '{print $NF}' > /tmp/blob_urls.txtThen deleted in batches using xargs:
head -100 /tmp/blob_urls.txt | xargs vercel blob del
sed -n '101,200p' /tmp/blob_urls.txt | xargs vercel blob del
# ... repeat through 701-760Each batch returns:
Vercel CLI 50.4.9
Deleting blob
> Success! Blob deleted
vercel blob del accepts multiple URLs as positional args and deletes them all in one call. Batches of 100 worked fine within default timeout.
Where We Landed
All 760 blobs deleted. User also removed the blob store entirely from the Vercel dashboard afterward.
Takeaways
vercel blob list --rw-token TOKENdoesn't work despite being documented in--help. UseBLOB_READ_WRITE_TOKEN=TOKENenv var instead.vercel blob delaccepts multiple URLs as args — no need for a loop, just xargs.vercel blob list --limit 1000is the max page size. For stores with >1000 items, you'd need to paginate with--cursor.- The CLI only shows "Success! Blob deleted" (singular) even when deleting hundreds — no count or progress indicator.