A Chrome extension that scans your entire Gmail inbox and mass deletes old and junk emails — while always protecting your starred and important ones.
No subscription. No backend. Everything runs in your browser.
Inbox Scanner — Scans your entire inbox and shows you:
- Total email count and storage used
- Breakdown by year (2010–present)
- Breakdown by category (Promotions, Social, Updates, Forums, Spam)
- Top 20 senders from junk categories
Year-Based Deletion — Pick exactly which years to nuke. Old years are pre-selected for you.
Category Cleanup — Delete all Promotions, Social, Updates, Forums, or Spam with one click.
Sender Cleanup — See your top junk senders, check the ones you want gone.
Safety First
- Starred and Important emails are always excluded from every query (server-side)
- Client-side double-check on every email's labels before deletion
- Preview mode counts emails before deleting anything
- Default mode moves to Trash (recoverable for 30 days)
- Permanent delete requires an explicit toggle + confirmation
Reliable
- Survives Chrome restarts — saves progress after every batch
- Pause, resume, or cancel any running job
- Handles Gmail API rate limits with automatic backoff
- Go to console.cloud.google.com
- Create a new project (e.g., "gmail-nuke")
- Enable the Gmail API: APIs & Services → Library → search "Gmail API" → Enable
- APIs & Services → OAuth consent screen:
- User type: External
- App name: "Gmail Nuke"
- Add your email as a test user
- Add scopes:
gmail.readonlyandgmail.modify
- APIs & Services → Credentials → Create Credentials → OAuth client ID:
- Application type: Chrome Extension
- Item ID: (get this from step 3 first, then come back)
- Open Chrome →
chrome://extensions - Enable Developer mode (top right)
- Click Load unpacked → select this folder
- Copy the extension ID from the card
- Go back to Google Cloud → Credentials → edit your OAuth client
- Paste the extension ID into the Item ID field
- Copy the Client ID (
...apps.googleusercontent.com) - Open
manifest.json→ replaceYOUR_CLIENT_ID.apps.googleusercontent.comwith your Client ID - Back to
chrome://extensions→ click refresh on Gmail Nuke
- Click the Gmail Nuke icon in your toolbar
- Sign in when prompted (click "Advanced" → "Go to Gmail Nuke" on the warning)
- The inbox scan runs automatically
- Use the dashboard tabs to select what to delete
- Hit Preview to count, or Delete Selected to go
Every single query sent to Gmail includes -is:starred -is:important. This tells Gmail's API to never return those emails in results. On top of that, before any batch delete, the extension checks each message's labelIds — if STARRED or IMPORTANT is present, it skips that message.
The queries are built dynamically from the dashboard UI. To add custom queries, edit the getSelectedQueries() function in popup.js.
Gmail search syntax reference: support.google.com/mail/answer/7190
Examples:
- Specific sender:
from:noreply@example.com -is:starred -is:important - Specific label:
label:old-stuff -is:starred -is:important - Large emails:
larger:10M -is:starred -is:important - Read emails only:
is:read -is:starred -is:important
- Vanilla JavaScript (no framework, no build step)
- Chrome Extension Manifest V3
- Gmail REST API via
chrome.identity - Zero dependencies
Is my data safe? Yes — the extension talks directly to Gmail's API from your browser. No data is sent anywhere else.
Can I undo? In Trash mode (the default): yes, go to Gmail → Trash. Everything stays for 30 days. In Permanent Delete mode: no, it's gone forever.
The scan numbers say "~" — are they exact?
Gmail's resultSizeEstimate is approximate for large result sets. The actual delete count will be exact.
It stopped mid-way? Reopen the popup — it auto-detects incomplete jobs and offers to resume.
MIT — do whatever you want with it.