Docs / Sending and domains
Migrating from Gmail SMTP
Apps that send through smtp.gmail.com with an app password are limited to the account's daily cap (about 500 recipients a day for a personal account, 2,000 per user for Google Workspace) and send from a personal mailbox, with no bounce handling, suppression list or delivery events. Moving the app to OneSend only changes its SMTP settings.
SMTP settings
| Setting | Gmail | OneSend |
|---|---|---|
| Host | smtp.gmail.com | Your OneSend host |
| Port | 465 or 587 | 2587 (ONESEND_SMTP_PORT) |
| Security | SSL/TLS or STARTTLS | STARTTLS when the server has TLS configured (SMTP); without TLS, only clients on the same host can authenticate |
| Username | Your Gmail address | Any value, for example onesend |
| Password | App password | A OneSend API key (Sending only or Full access) |
Optional headers on each message: X-OneSend-Tags: signup,welcome, X-OneSend-Policy: <routing policy>, and X-OneSend-Type: broadcast for marketing email. Messages appear in Logs with source smtp.
To send through the REST API instead, use POST /v1/emails or an SDK; see Getting started.
Keeping Gmail as a provider
You can connect the Gmail account as an SMTP provider in OneSend (see SMTP as a provider) and put a sending service in front of it in the routing policy. Mail sent through Gmail is signed with DKIM as gmail.com, so for a custom From domain it does not align with DMARC; use it as a last fallback for low volumes, or not at all. Google's terms do not allow bulk or automated marketing mail from personal accounts.
Sending domain
With Gmail, mail came from @gmail.com or a "Send mail as" address. With OneSend, send from your own domain:
- Buy a domain if you do not have one, and add it under Senders & domains after connecting at least one sending provider.
- Publish the records in the DNS plan: the
_onesend-verifyTXT, each provider's DKIM, the return-path records and a DMARC record (start withp=none; Deliverability tools → DMARC generator builds one). - Run Deliverability tools → DNS check on the domain.
Do not change the MX records of a domain that receives mail in Google Workspace: sending through OneSend needs no MX change. If you add an SPF include for a provider, merge it into the existing record (one SPF record per name) and keep include:_spf.google.com for Workspace mail; the SPF builder counts the lookups.
Cutover checklist
- Connect a sending provider and verify the domain (see above).
- Create an API key; start with a test key (
os_test_…) so nothing is delivered. - Change the app's SMTP settings to the table above and send a test message. Check Logs.
- Switch to a live key.
- Revoke the Gmail app password once the app no longer uses it.
See also the general cutover checklist.