I always wonder what the ‘unsubscribe’ link does. Some businesses automatically subscribe people to spam campaigns without the user’s consent. For such cases, the most logical explanation would be that the ‘unsubscribe’ link verifies the existence of the email. As a result, every unsubscribed email address is potentially worth double because it provides proof that someone is using it. So, why would spammers want to remove it?
From observation: the legit businesses, especially the ones that use third-party “transactional email” services like Mailgun and Postmark that need to care about their reputation, tend to behave well. Apart from spuriously re-adding your email to their list every year or whenever they migrate software.
The actual spammers absolutely use unsubscribe links to verify the existence of the email… or more often, it just leads directly to malware.
… which is built around Google Sheets and Google’s own GMail automation API, Google Apps Script (which uses JavaScript/TypeScript anyway, but doesn’t require any separate hosting or credentials).
welp, I came here to post this (it’s my repo) but you beat me to it!
My version is much shittier than OP’s, but does get around the “how do you send the email” problem by just sending the email from your own Gmail account. Annoyingly neither the OP or I solve the “visit the website and click buttons” kind of unsubscribe flow. I’ve been thinking about building an add-on daemon for gmail-unsubscribe that you could run on your own computer that polls the spreadsheet for “visit the website” type deals, and then uses Chromium+Playwright to actually visit the website and click the buttons for you. I wonder how far you could get if you hook up a dumb multi-modal local AI and ask it where to click? It could be the move.
Oh, I wasn’t meaning it as a criticism! Apologize if it came off that way. It was just my gut reaction since I’m an active user of the other tool for years and have customized it over the years for my own use, so I know how much it takes to maintain even that lightweight setup.
I decided that in addition to bulk spam unsubscribing, I also wanted to have an automatic inbox cleaner and to generate my GMail Filters programmatically from JSON. The inbox cleaner implements something I call a “delayed filter.” That is, the email still arrives to the inbox right away (properly labeled), but every 15-30 minutes the email is automatically moved out of the inbox if it matches the filter rules that indicate it’s not an urgent/important/personal email.
This gives me the nice effect that for many classes of emails (invoices, orders, newsletters, travel confirmations, etc.) I can see them show up in my inbox immediately upon receipt, but then if I am not monitoring my email for a few hours, they get auto-tidied. I really should open source it since it’s pretty cool, but I haven’t gotten around to it!
Among other things, my structured JSON filters let me do an especially good job of identifying “personal” emails and separating away “newsletters that I care about, but that can be read in bulk later.”
All this is done with Google Apps Script just like the original unsubscriber tool.
I also implemented a basic tool to export my most recent 500 emails into a Google Sheet. This just helps me identify patterns I can use to write new filter rules.
I’m rather shocked at the large amount of spam in the opening screenshot. I wonder why I get nowhere near that much spam (and almost all that I do get is automatically sent to the Spam folder), such that Gmail’s Unsubscribe button is entirely sufficient to deal with it.
Appreciate this being self-hostable for privacy reasons. I’d be interested to extend it for generic IMAP/JMAP so I can use the same thing for FastMail. Generally speaking this is the first I’ve heard of Gmail/Yahoo implementing the unsubscribe header which is pretty exciting.
Yeah the intention was to launch it with a hosted version that people could use for free. But google was a massive PITA with casa and AWS wouldn’t let me do this with SES so it would cost too much.
The majority of spam I get is from unique email addresses for political campaigns because I gave fucking Bernie Sanders $5 nearly a decade ago. My personal email address has been virtually ruined, I’ve had to create a new one. I mark one as spam, they find a new email. I’ll unsubscribe, mark as spam, etc. They don’t get the hint.
I get this too and it’s insane. I donated to Andrew Yang early in his campaign because of his message to make spam illegal, robocalling especially illegal, and now his associates send me regular emails I don’t want to receive and can’t seem to unsubscribe from enough of. The irony.
I am convinced the “unsubscribe” button in emails is wired up to /dev/null more often than not. If I click “unsubscribe” and I continue to get emails after a day or so, then I just set up an email filter to automatically delete email from the sender (looking at you, Dick’s Sporting Goods, whose emails pile up in the Trash folder to the tune of 5-7 per day.)
Do you mean an “Unsubscribe” link offered by the sender of the message? The “Unsubscribe” button to which https://www.aspiring.dev/bulk-unsubscribe/ refers is one offered by Gmail.
I’ve seen a few senders eventually disrespect unsubscription requests that I sent using their own unsubscription links, but either all my uses of Gmail’s Unsubscribe button were respected or Gmail rejected any further messages from those senders. (However, I evidently don’t get nearly as much spam as the author; my experience may not be representative.)
I always wonder what the ‘unsubscribe’ link does. Some businesses automatically subscribe people to spam campaigns without the user’s consent. For such cases, the most logical explanation would be that the ‘unsubscribe’ link verifies the existence of the email. As a result, every unsubscribed email address is potentially worth double because it provides proof that someone is using it. So, why would spammers want to remove it?
From observation: the legit businesses, especially the ones that use third-party “transactional email” services like Mailgun and Postmark that need to care about their reputation, tend to behave well. Apart from spuriously re-adding your email to their list every year or whenever they migrate software.
The actual spammers absolutely use unsubscribe links to verify the existence of the email… or more often, it just leads directly to malware.
This seems a bit over-engineered vs something like this:
https://github.com/justjake/gmail-unsubscribe
… which is built around Google Sheets and Google’s own GMail automation API, Google Apps Script (which uses JavaScript/TypeScript anyway, but doesn’t require any separate hosting or credentials).
welp, I came here to post this (it’s my repo) but you beat me to it!
My version is much shittier than OP’s, but does get around the “how do you send the email” problem by just sending the email from your own Gmail account. Annoyingly neither the OP or I solve the “visit the website and click buttons” kind of unsubscribe flow. I’ve been thinking about building an add-on daemon for gmail-unsubscribe that you could run on your own computer that polls the spreadsheet for “visit the website” type deals, and then uses Chromium+Playwright to actually visit the website and click the buttons for you. I wonder how far you could get if you hook up a dumb multi-modal local AI and ask it where to click? It could be the move.
Sure, but sometimes it’s fun to make stuff yourself :)
Oh, I wasn’t meaning it as a criticism! Apologize if it came off that way. It was just my gut reaction since I’m an active user of the other tool for years and have customized it over the years for my own use, so I know how much it takes to maintain even that lightweight setup.
What customizations did you make?
It’s described a bit in this blog post:
https://amontalenti.com/2019/11/04/work-is-a-queue-of-queues
I decided that in addition to bulk spam unsubscribing, I also wanted to have an automatic inbox cleaner and to generate my GMail Filters programmatically from JSON. The inbox cleaner implements something I call a “delayed filter.” That is, the email still arrives to the inbox right away (properly labeled), but every 15-30 minutes the email is automatically moved out of the inbox if it matches the filter rules that indicate it’s not an urgent/important/personal email.
This gives me the nice effect that for many classes of emails (invoices, orders, newsletters, travel confirmations, etc.) I can see them show up in my inbox immediately upon receipt, but then if I am not monitoring my email for a few hours, they get auto-tidied. I really should open source it since it’s pretty cool, but I haven’t gotten around to it!
Among other things, my structured JSON filters let me do an especially good job of identifying “personal” emails and separating away “newsletters that I care about, but that can be read in bulk later.”
All this is done with Google Apps Script just like the original unsubscriber tool.
I also implemented a basic tool to export my most recent 500 emails into a Google Sheet. This just helps me identify patterns I can use to write new filter rules.
I’m rather shocked at the large amount of spam in the opening screenshot. I wonder why I get nowhere near that much spam (and almost all that I do get is automatically sent to the Spam folder), such that Gmail’s Unsubscribe button is entirely sufficient to deal with it.
Appreciate this being self-hostable for privacy reasons. I’d be interested to extend it for generic IMAP/JMAP so I can use the same thing for FastMail. Generally speaking this is the first I’ve heard of Gmail/Yahoo implementing the unsubscribe header which is pretty exciting.
Thanks for the blog and source code!
Yeah the intention was to launch it with a hosted version that people could use for free. But google was a massive PITA with casa and AWS wouldn’t let me do this with SES so it would cost too much.
The majority of spam I get is from unique email addresses for political campaigns because I gave fucking Bernie Sanders $5 nearly a decade ago. My personal email address has been virtually ruined, I’ve had to create a new one. I mark one as spam, they find a new email. I’ll unsubscribe, mark as spam, etc. They don’t get the hint.
I get this too and it’s insane. I donated to Andrew Yang early in his campaign because of his message to make spam illegal, robocalling especially illegal, and now his associates send me regular emails I don’t want to receive and can’t seem to unsubscribe from enough of. The irony.
I am convinced the “unsubscribe” button in emails is wired up to /dev/null more often than not. If I click “unsubscribe” and I continue to get emails after a day or so, then I just set up an email filter to automatically delete email from the sender (looking at you, Dick’s Sporting Goods, whose emails pile up in the Trash folder to the tune of 5-7 per day.)
Do you mean an “Unsubscribe” link offered by the sender of the message? The “Unsubscribe” button to which https://www.aspiring.dev/bulk-unsubscribe/ refers is one offered by Gmail.
I’ve seen a few senders eventually disrespect unsubscription requests that I sent using their own unsubscription links, but either all my uses of Gmail’s Unsubscribe button were respected or Gmail rejected any further messages from those senders. (However, I evidently don’t get nearly as much spam as the author; my experience may not be representative.)
Yeah.
Hmm. That’s good to know. I’ll give it a try. Failing that, it’s not too onerous to keep adding delete rules.