Solutions
Services
AI Growth
Industries
Resources
Pricing
Book a call
Home/Blog/Building our sunset sequence: how we automated list cleaning
Playbook·April 28, 2026·9 min read

Building our sunset sequence: how we automated list cleaning

The architectural shape of the sunset email sequence we just shipped — Supabase views, namespaced HMAC tokens, GitHub Actions cron, and why 90 days is the threshold we picked.

QB
Quang Bui
Founder, digicore101
Editorial illustration: a row of paper envelopes, half of them faded gray and half lit in orange-coral, against cream paper.
#email#deliverability#lifecycle-marketing#supabase#resend#playbook
▶ TL;DR
  • A sunset sequence is the cheapest deliverability win you can ship — pruning silent contacts protects sender reputation for the engaged ones.
  • We chose 90 days of zero opens/clicks as the inactivity threshold. Tighter (60d) burns engaged-but-quiet readers; looser (180d) lets the rot compound.
  • Three emails over 11 days: check-in (day 1), last chance (day 6), goodbye (day 12). Each one is a one-click "stay subscribed" decision, not a guilt trip.
  • The architecture is a Supabase view + two GitHub Actions crons + Resend Automations. Total moving parts: small. Total monthly cost: $0 at our volume.
  • Signed HMAC tokens are namespaced by intent (unsubscribe vs sunset-stay) so the same recipient URL can't be reused across endpoints — a small but important correctness move.
▶ Q&A

Frequently asked.

Q.01

What is a sunset email sequence?

A small lifecycle automation that finds inactive email subscribers, asks them once if they want to stay, and removes them from active sends if they don't respond. The point is to protect deliverability for engaged subscribers, since silent contacts drag down sender reputation over time.

Q.02

How long should the inactivity window be before sunsetting?

90 days is a good default for monthly newsletters. Drop to 30–60 days if you send daily/weekly. Push to 180 days only if your send cadence is quarterly. The principle is "missed enough sends to clearly not be reading anymore" — measured against your actual rhythm.

Q.03

How many emails should a sunset sequence have?

Three is the sweet spot: a check-in at day 1, a last chance at day 6, and a goodbye at day 12 after the actual unsubscribe. Two emails feels abrupt; four feels like guilt-tripping. The goodbye is the one most lists skip and shouldn't — it's what makes the whole flow feel respectful instead of sneaky.

Q.04

What should the "stay subscribed" link actually do?

Clicking it should mark the contact as engaged (so they're excluded from the sunset rule going forward) and cancel any pending sunset emails. Don't make the user fill out a form — friction is the enemy of a clean signal. One click in, one click confirmation, done.

Q.05

How does removing inactive subscribers improve deliverability?

Mailbox providers (Gmail, Outlook, Apple) use engagement rates — opens, clicks, replies — as a primary input to whether your future sends land in the inbox or the promotions tab. A list with 10% engaged readers and 90% silent looks worse to providers than a list with 50% engaged and 50% silent, even if the absolute count of engaged readers is the same. Pruning is reputation hygiene.

Q.06

Can you sunset contacts you imported from a CRM or signup form?

Yes — engagement-based sunsetting applies to any contact regardless of source. In fact, contacts you imported (rather than opted in via email) often have lower base engagement, so the sunset window may be more generous to give them time to re-establish patterns. Watch your bounce rate on imports separately; bounces are a different (and more urgent) cleanup signal.