frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: mailtrim – find what's actually filling your Gmail inbox

29•chevuru•9h ago
I always assumed Gmail bloat came from large attachments. Turns out 3 senders were responsible for 30% of my inbox — thousands of tiny emails I'd never thought to clean up.

  I built mailtrim to surface this pattern:                                                                                                                                                                                                                                                                                                                               
                                           
  - ranks senders by actual storage impact (not just count)                                                                                                                                                                                                                                                                                                               
  - confidence scoring on what's safe to bulk-delete                                                                                                                                                                                                                                                                                                                    
  - 30-day undo on everything — nothing is permanent by default
  - runs entirely locally, no email data leaves your machine   
                                                                                                                                                                                                                                                                                                                                                                          
  Free, open source (MIT). No subscription, no backend.
                                                                                                                                                                                                                                                                                                                                                                          
  One friction point upfront: Gmail API setup is one-time, ~15 min.                                                                                                                                                                                                                                                                                                     
  After that it's just `mailtrim stats` and `mailtrim purge`.      
                                                             
  Keen to hear feedback on the confidence/safety model especially —                                                                                                                                                                                                                                                                                                       
  that's the part I'm least sure I've got right.                   
                                                                                                                                                                                                                                                                                                                                                                          
  https://github.com/sadhgurutech/mailtrim

Comments

chevuru•9h ago
Happy to help with setup if anyone tries it — GCP step is the only slightly annoying part right now.
salusinarduis•7h ago
I would love to use this on my iCloud mailbox. It seems odd to use the Gmail API instead of IMAP. Hopefully that becomes supported in the future because the project seems great.
chevuru•1h ago
Totally fair. This is probably the biggest limitation right now.

I started with the Gmail API because: - better performance vs IMAP for large mailboxes - easier access to size metadata per message

That said, IMAP support is something I definitely want to add. Especially for iCloud/Outlook users.

If I did add IMAP, would you be okay with: - slower scans - slightly less accurate size estimates

Or is parity with Gmail important?

chevuru•9h ago
Curious if others have noticed the same pattern — a few senders making up most of the inbox.
yesensm•8h ago
Very useful!
guessmyname•8h ago
Why thousands? You never read or delete all your emails within a day?

My inbox, which I have for almost two decades only has 28 emails in it. Not 28 unread emails, but 28 total emails. I delete everything within a day of receiving, except for every important things, hence why 28 of them still remain.

Keeping thousands of emails in your inbox, while virtually free, is an attack vector for hackers, and also a gold mine for advertisement brokers who pay email providers money to show you ads based on your daily habits.

drfloyd51•7h ago
28 important emails in 20 years? Would the information in those emails had gotten to you via a different vector if you did not have email? This sounds like a case for not having email.
collabs•7h ago
I am not saying I'm right, I'm just explaining how it got this bad.

See I used to have 2 MB on my hot mail and 4 MB on my Yahoo! Mail. I used to do exactly what you said. Then, I got invitation to Google mail. 1GB and counting!

I got lazy. I no longer had to delete mail anymore. So, it started accumulating. There. That's the whole story.

kaonwarb•7h ago
OP is aiming to help a quite common problem. Curious: how many others have you met with as spare of an email inbox as yours?
LiamPowell•8h ago
Did you really use a LLM to generate the sample output in your readme instead of just running the application? I noticed the borders were all misaligned and wondered if you had hardcoded the number of spaces, but I looked at the code and you haven't.

If you did generate the output with a LLM instead of just running it... why?

Also:

> It uses Claude AI for smart classification, but runs entirely locally: your emails never leave your machine.

How can both of these things be true? How can Claude be used as a classifier without sending your emails to Claude? From looking at the code it appears that you do in fact just send off emails to Claude, or at least the first 300-400 characters, so that line is just a complete lie.

CobrastanJorji•7h ago
I think the idea is that SOME of the classification (the "stats" command) works without AI, but it also supports some fancy and definitely-not-local Anthropic processing options.
chevuru•12m ago
The share text and README have been updated to accurately say "Core cleanup runs locally — AI commands send only subjects/snippets to Anthropic." The terminal sample outputs were illustrative; I'm recording a real asciinema session to replace them. PR #8 landed the README fix
chris_seaman•8h ago
Very cool! Congratulations on putting this together.

Was also tinkering with Gmail bloat but, admittedly, with a less ambitious approach. Definitely going to give it a try.

chevuru•1h ago
Thanks! The Gmail API setup is the only friction. Once Mailtrim auth completes, it's just two commands. Let me know if you hit anything.
trustfixsec•7h ago
Nice approach. Confidence scoring on what's the safe one to delete is smart, and that's the hardest part of any cleanup tool. How are you handling false positives? I've been thinking about similar confidence scoring in a different domain (security) and the calibration is really tricky when the cost of getting it wrong is high.
DigitallyBorn•7h ago
I would love it if it could run against archived messages (`in:anywhere -in:trash -in:spam`) ... I've been archiving all email for a very long time and being able to run stats and purge it would do wonders.
chevuru•1h ago
This is a great call. you're right that a lot of the "hidden bloat" sits in archived mail, not the inbox.

Right now mailtrim only looks at inbox by default, but adding support for something like:

  in:anywhere -in:trash -in:spam
is very doable.

Would you expect this as: 1) a flag (e.g. --all-mail) 2) or the default behavior?

Happy to prioritize this if it's useful. Feels like it would surface way more interesting results.

chevuru•11m ago
Now shipped: --scope anywhere is now live — scans all mail (inbox, archived, sent), not just inbox. Works with stats, purge, and sync. Thanks for the push

Show HN: A game where you build a GPU

https://jaso1024.com/mvidia/
797•Jaso1024•19h ago•163 comments

Show HN: OsintRadar – Curated directory for osint tools

https://osintradar.com/
18•lexalizer•6h ago•1 comments

Show HN: I built a small app for FSI German Course

https://detawk.com/
39•syedmsawaid•3d ago•13 comments

Show HN: sllm – Split a GPU node with other developers, unlimited tokens

https://sllm.cloud
165•jrandolf•20h ago•79 comments

Show HN: I made open source, zero power PCB hackathon badges

https://github.com/KaiPereira/Overglade-Badges
118•kaipereira•21h ago•11 comments

Show HN: White Border

https://awhiteborder.com/
4•artiomyak•1h ago•2 comments

Show HN: Contrapunk – Real-time counterpoint harmony from guitar input, in Rust

https://contrapunk.com/
78•waveywaves•11h ago•34 comments

Show HN: M. C. Escher spiral in WebGL inspired by 3Blue1Brown

https://static.laszlokorte.de/escher/
99•laszlokorte•16h ago•16 comments

Show HN: TurboQuant-WASM – Google's vector quantization in the browser

https://github.com/teamchong/turboquant-wasm
154•teamchong•21h ago•6 comments

Show HN: Bb – Windows API viewer for hackers, in the browser

https://cristeigabriela.github.io/bb-viewer/index.html
3•gabriela_c•5h ago•0 comments

Show HN: I built a frontpage for personal blogs

https://text.blogosphere.app/
757•ramkarthikk•1d ago•190 comments

Show HN: Apfel – The free AI already on your Mac

https://apfel.franzai.com
718•franze•2d ago•146 comments

Show HN: Pluck – Copy any UI from any website, paste it into AI coding tools

https://www.pluck.so/
17•bring-shrubbery•1d ago•13 comments

Show HN: Signals – finding the most informative agent traces without LLM judges

https://arxiv.org/abs/2604.00356
3•sparacha•9h ago•0 comments

Show HN: ImPlot v1.0 – 6 years of Immediate-mode plotting for Dear ImGui

https://github.com/epezent/implot
3•brenocq•4h ago•2 comments

Show HN: ctx – an Agentic Development Environment (ADE)

https://ctx.rs
49•luca-ctx•1d ago•52 comments

Show HN: Travel Hacking Toolkit – Points search and trip planning with AI

https://github.com/borski/travel-hacking-toolkit
92•borski•1d ago•37 comments

Show HN: Ownscribe – local meeting transcription, summarization and search

https://github.com/paberr/ownscribe
11•paberr•23h ago•0 comments

Show HN: DocMason – Agent Knowledge Base for local complex office files

https://github.com/jetxu-llm/docmason
7•Jet_Xu•19h ago•0 comments

Show HN: Vibooks – Local-first bookkeeping software built for AI agents

https://vibooks.ai/
2•adshao•11h ago•1 comments

Show HN: SeekLink – Local hybrid search and link discovery for Obsidian vaults

https://github.com/simonsysun/seeklink
2•simonsysun•11h ago•0 comments

Show HN: Dull – Instagram Without Reels, YouTube Without Shorts (iOS)

https://getdull.app
152•kasparnoor•3d ago•117 comments

Show HN: Mtproto.zig – High-performance Telegram proxy with DPI evasion

https://github.com/sleep3r/mtproto.zig
21•slp3r•1d ago•14 comments

Show HN: Self-Host Excalidraw with Collaboration and Storage

https://github.com/ZimengXiong/ExcaliDash
2•zimengx•13h ago•1 comments

Show HN: Made a little Artemis II tracker

https://artemis-ii-tracker.com/
149•codingmoh•2d ago•56 comments

Show HN: Ismcpdead.com – Live dashboard tracking MCP adoption and sentiment

https://ismcpdead.com
35•sagirodin•1d ago•23 comments

Show HN: Artemis.fyi - Real-time tracker for the Artemis II Moon mission

https://artemis.fyi/
9•dmk•13h ago•0 comments

Show HN: Chrome extension prototype for cross-tab/frame network interception

https://github.com/vsromanc/framelink
3•vsromanc•13h ago•1 comments

Show HN: SwarmFeed – An X-like social platform built for AI agents

https://www.swarmfeed.ai/
3•jamesweb•14h ago•0 comments

Show HN: Dev Personality Test

https://personality.4m1r.dev/
5•4m1rk•14h ago•3 comments