Email Notifications
Before It's Gone can send expiry alerts and inventory digests to any email address using either Resend (recommended) or your own SMTP server.
Setup
Open the app and go to Settings → Email Notifications.
1. Choose a provider
| Provider | Best for |
|---|---|
| Resend | Easiest setup: one API key, reliable delivery |
| SMTP | Self-hosted mail servers, Gmail SMTP, Fastmail, etc. |
2. Configure credentials
Resend
- Create a free account at resend.com.
- Generate an API key: API Keys → Create API Key. Set permission to Sending access.
- Paste the key (starts with
re_) into Resend API key in Settings.
SMTP
Fill in the fields that match your mail server:
| Field | Example |
|---|---|
| SMTP host | smtp.gmail.com |
| SMTP port | 587 (STARTTLS) or 465 (SSL) |
| Username | you@gmail.com |
| Password | App password (not your login password) |
| Use TLS | On for port 587/465, off for local servers on port 25 |
Gmail users: Enable 2-factor authentication on your Google account, then generate an App Password. Your regular Gmail password will not work.
3. Set a recipient
Enter the email address that should receive notifications in the Recipient email field.
4. Configure digest
| Setting | Description |
|---|---|
| Never | No automatic digest emails. |
| Daily | One email per day at the chosen time. |
| Weekly | One email per week (sent at least 6.5 days after the last digest). |
| Send time | Time of day to send the digest (24-hour, e.g. 08:00). |
5. Test
Click Send test email to verify your credentials before relying on them.
Digest content
A digest email includes:
- Expiring items: items within your configured warning window (amber) or already expired (red), with expiry date, quantity, and location.
- Low stock: items at or below their low-stock threshold, with quantity and threshold.
If nothing is expiring or low, no digest is sent for that cycle.
Pause and snooze
To temporarily stop digest emails, use the Pause emails controls:
| Option | Effect |
|---|---|
| 7 days | Resumes automatically after 7 days. |
| 30 days | Resumes automatically after 30 days. |
| Indefinitely | Stays paused until you click Resume in Settings. |
A banner in the app header shows when emails are paused.
Credential storage
Email credentials (API key or SMTP password) are stored in email-settings.json inside Electron's userData directory, not in the browser's localStorage or IndexedDB, and not synced to any cloud. The file is readable only by your user account.
| Platform | Path |
|---|---|
| Linux | ~/.config/before-its-gone/email-settings.json |
| macOS | ~/Library/Application Support/before-its-gone/email-settings.json |
| Windows | %APPDATA%\before-its-gone\email-settings.json |
SMTP provider guide
Quick reference for common mail providers. The app only sends email (SMTP); it does not read inboxes.
Provider quick reference
| Provider | Host | Port | TLS | Auth |
|---|---|---|---|---|
| Gmail | smtp.gmail.com | 587 | On | App password |
| Outlook / Hotmail | smtp-mail.outlook.com | 587 | On | Account password |
| Microsoft 365 | smtp.office365.com | 587 | On | Account password |
| Fastmail | smtp.fastmail.com | 587 | On | App password |
| Yahoo Mail | smtp.mail.yahoo.com | 587 | On | App password |
| iCloud Mail | smtp.mail.me.com | 587 | On | App-specific password |
| Proton Mail Bridge | 127.0.0.1 | 1025 | Off | Bridge password |
| Custom / self-hosted | your server | 25 / 587 / 465 | Varies | Varies |
Port guide
| Port | Protocol | When to use |
|---|---|---|
| 25 | SMTP plain | Server-to-server relay; usually blocked by ISPs for end-user clients. |
| 587 | SMTP + STARTTLS | Recommended. Starts unencrypted, upgrades to TLS. Enable Use TLS in settings. |
| 465 | SMTP over SSL | Legacy but still common. Encrypted from the first byte. Enable Use TLS. |
Gmail
Google does not allow SMTP with your regular login password. Generate an App Password (requires 2-Step Verification):
- Go to myaccount.google.com/apppasswords.
- Click Create app password, name it, and click Create.
- Copy the 16-character password shown.
| Field | Value |
|---|---|
| SMTP host | smtp.gmail.com |
| SMTP port | 587 |
| Username | your full Gmail address |
| Password | the 16-character app password |
| Use TLS | On |
Outlook / Hotmail / Live
| Field | Value |
|---|---|
| SMTP host | smtp-mail.outlook.com |
| SMTP port | 587 |
| Username | your full Outlook address |
| Password | your Microsoft account password |
| Use TLS | On |
Microsoft 365 organizational accounts may require OAuth2 or per-app SMTP settings configured by your IT admin.
Fastmail
Fastmail requires an App Password: Settings → Privacy & Security → Third-party apps → New App Password.
| Field | Value |
|---|---|
| SMTP host | smtp.fastmail.com |
| SMTP port | 587 |
| Username | your full Fastmail address |
| Password | the app password |
| Use TLS | On |
Yahoo Mail
Yahoo requires an App Password (requires 2-Step Verification): Account Security → App passwords → Generate app password.
| Field | Value |
|---|---|
| SMTP host | smtp.mail.yahoo.com |
| SMTP port | 587 |
| Username | your full Yahoo address |
| Password | the app password |
| Use TLS | On |
iCloud Mail
Apple requires an app-specific password: appleid.apple.com → Sign-In and Security → App-Specific Passwords → Generate.
| Field | Value |
|---|---|
| SMTP host | smtp.mail.me.com |
| SMTP port | 587 |
| Username | your full iCloud address (you@icloud.com) |
| Password | the app-specific password |
| Use TLS | On |
Proton Mail (via Bridge)
Proton Mail requires the Proton Mail Bridge desktop app to be running alongside Before It's Gone. Install and sign in to Bridge, then find the local SMTP credentials in the Bridge UI.
| Field | Value |
|---|---|
| SMTP host | 127.0.0.1 |
| SMTP port | 1025 (or as shown in Bridge) |
| Username | your Proton address (as shown in Bridge) |
| Password | the Bridge-generated password |
| Use TLS | Off (Bridge handles encryption internally) |
Self-hosted (Postfix / Sendmail / Mailcow / etc.)
| Configuration | Host | Port | TLS | Auth |
|---|---|---|---|---|
| Local relay (no auth) | localhost | 25 or 587 | Off | Leave username/password blank |
| Authenticated submission | your server hostname | 587 or 465 | On | Your mail user credentials |
If your server uses a self-signed certificate, TLS negotiation may fail. Use port 587 with TLS off only on local/private networks, or configure a valid certificate (Let's Encrypt recommended) for public servers.
Troubleshooting
Test email not received
- Check your spam/junk folder.
- Verify the API key has Sending access permission (Resend).
- Check Resend's dashboard for delivery logs and error details.
- Resend free accounts cannot send to unverified domains by default; confirm your recipient address in the Resend dashboard if required.
"Connection refused" or timeout (SMTP)
- Verify the host and port are correct.
- Check that your mail server allows SMTP connections from your machine (firewall rules, ISP blocking of port 25).
- For self-hosted servers, confirm the SMTP daemon is running (
systemctl status postfixetc.).
"Authentication failed" or "535" (SMTP)
- For Gmail, Yahoo, Fastmail, and iCloud you must use an app password, not your login password.
- Your account may require 2-factor authentication to be enabled before app passwords are available.
- Username must be your full email address (e.g.
you@gmail.com, notyou).
Emails arrive in spam
- The sender address (
notifications@beforeitsgone.local) has no associated domain record, which may trigger spam filters. - Configure SPF/DKIM records if you control the sending domain, or use Resend which handles deliverability automatically.
- Whitelist the sender address in your email client.
Test email works but digests don't arrive
- Confirm Digest frequency is set to Daily or Weekly (not Never).
- The digest fires at the configured Send time only if the app is running and the system clock reaches that time.
- No digest is sent when nothing is expiring or low-stock; the app only sends when there's something to report.