=== SMTPing Email Suite: SMTP, Newsletter & Email Verification ===
Contributors: smtping
Tags: smtp, newsletter, email verification, email log, transactional email
Requires at least: 6.2
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 0.27.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

SMTP mailer, newsletter and email verification in one plugin: send reliably, grow your list and never mail a bad address.

== Description ==

WordPress sends email with PHP mail() by default. Most hosts are not set up for it, so password resets, WooCommerce orders and form notifications land in spam or never arrive. SMTPing Email Suite sends every WordPress email through a real SMTP server or an email API, and checks each recipient before the email leaves your site.

= Send through a real provider =

* **12 mailers**: Other SMTP (any server), Google / Gmail, Microsoft 365 / Outlook, Zoho Mail, Amazon SES, SendGrid, Mailgun, Postmark, Brevo, SparkPost, Resend and Elastic Email.
* **Test connection**: logs in to your SMTP server without sending an email and tells you exactly what is wrong: unknown host, blocked port, wrong encryption for the port, refused login or a temporary block after too many attempts.
* **Backup connection**: if the main mailer fails, a second one sends the email automatically.
* **Sending queue and rate limit**: emails are sent in the background, so pages load faster and you stay under your provider limits. Each email is retried up to 3 times.
* **Sender control**: force the from email and from name on every email, and send bounces back to your address.
* Passwords and API keys are encrypted in the database and never shown again.

= Check recipients before sending =

Every recipient is checked with the SMTPing verification API before the email is sent. Invalid, spamtrap, disposable, blacklisted, complainer, spambot and full-inbox addresses are not sent, and neither are addresses that already bounced. You choose what happens: remove the risky recipient and send to the others, or do not send the email at all.

* 1 credit per new address, results are kept 30 days, so the same address is never paid twice in a month.
* Unknown results are never charged.
* Every SMTPing account gets 25 free credits per day.
* Without an API key, only addresses that already bounced are skipped.

= See what happened to every email =

* **Dashboard**: emails sent and failed, risky recipients removed, emails delivered by the backup, a chart over 7, 30 or 90 days, and which plugins send your email.
* **Email log**: subject, recipients, status, mailer and error for every email, with search, filters and CSV export. The email content is never stored. You choose how long the log is kept.
* **Bounced addresses**: the list of addresses rejected permanently by the receiving server.
* **Domain health**: SPF, DKIM, DMARC and MX checked live in your DNS.

= Alerts =

Get an email, a Slack, Discord or Microsoft Teams message, or a JSON webhook when an email fails, when the backup connection takes over, or when the queue is stuck for more than 30 minutes. One alert per type every 15 minutes at most. Alert emails are sent with PHP mail(), so they can still arrive when your mailer is down.

= WP-CLI =

* `wp smtping status`: mailer, queue, log and credits.
* `wp smtping test you@example.com`: send a test email.
* `wp smtping queue run` and `wp smtping queue retry`: process the queue now, or send failed emails again.
* `wp smtping log --status=failed --format=csv`: read the email log.
* `wp smtping alert-test`: send a test alert.

= Deliverability check =
One click checks SPF, DKIM, DMARC, MX and blocklists for your sending domain, with a score and the exact fix for each issue.

= Forms =
Drag and drop builder with 25 field types, conditional logic, multi-step forms, entry preview and a math captcha. 17 ready-made templates, embedded forms and popups (delay, scroll, exit intent). Also connects to 31 form plugins, so signups from Contact Form 7, WPForms, Gravity Forms, Elementor and others join your lists.

= Newsletter and campaigns =
Lists, tags, double opt-in, a preference page and one-click unsubscribe. Emails are designed in the WordPress block editor, pasted as HTML or imported from a zip. Campaigns can be scheduled and report opens, clicks and unsubscribes. Newsletter features need WordPress 7.0 or later.

= Automation =
Welcome series, abandoned cart, new post and new product announcements, weekly digest, win-back, first order follow-up and review requests, built step by step with waits, conditions, tags and lists.

= Transactional emails =
A branded template for WordPress emails, your logo and color on WooCommerce emails, a dedicated connection for transactional email, smart routing rules, and a switch for every WordPress and WooCommerce notification.

= AI and MCP =
Write emails, subject lines and form copy with the AI provider connected to WordPress (WordPress 7.0+, Settings > Connectors). SMTPing registers its abilities with the WordPress Abilities API, so the official MCP Adapter plugin can let Claude, ChatGPT, Cursor or Codex read your email stats, logs, deliverability and newsletter data. SMTPing stores no AI key and runs no server of its own.

== Installation ==

1. In WordPress, go to **Plugins > Add New**, search for **SMTPing Email Suite**, click **Install Now**, then **Activate**.
2. Open **SMTPing > Sending** and pick your mailer.
3. Fill in the fields. For an SMTP server, click **Test connection**: a successful test saves your settings.
4. Optional: paste your SMTPing API key under **Check recipients before sending** and click **Test API key**.
5. Send a test email from the bottom of the page.

== Frequently Asked Questions ==

= Why are my WordPress emails not sending? =

WordPress uses PHP mail(), which many hosts block or which is not authenticated with SPF and DKIM. Receiving servers then reject the email or put it in spam. Sending through an SMTP server or an email API with your own domain fixes it.

= Which mailer should I choose? =

For a small site, the SMTP server of your email host, Gmail or Microsoft 365 is enough. For a shop or a busy site, use a sending service such as Brevo, SendGrid, Amazon SES, Postmark or Mailgun: they handle volume and give better delivery.

= My test connection fails. What do I check? =

Port 465 needs SSL/TLS, port 587 needs STARTTLS. Use the full email address as username. If the server refuses the login after several tries, wait 15 to 30 minutes before testing again: many providers block logins temporarily after repeated failures.

= Does the recipient check slow down my site? =

With the sending queue on, emails are checked and sent in the background, so visitors do not wait. Results are cached for 30 days.

= Do I need an SMTPing account? =

No. Sending, the queue, the log and alerts work without an account. An SMTPing API key is only needed to check recipients before sending. Every account gets 25 free credits per day.

= Can I use it with WP Mail SMTP or another SMTP plugin? =

Deactivate the other SMTP plugin first. Two plugins that take over WordPress email at the same time can conflict.

= Does it work with WooCommerce and form plugins? =

Yes. Any plugin that sends email with wp_mail() goes through SMTPing Email Suite, including WooCommerce, Contact Form 7, WPForms, Gravity Forms and Elementor forms.

== External services ==

This plugin connects to external services to send your emails and, if you enable it, to check recipients.

= Your sending provider =

Each email is sent to the provider you select, and only to that provider (and to your backup provider if the main one fails). The plugin sends the sender, recipients, subject, body, headers and attachments of the email, and your credentials for that provider. Nothing is sent until you configure a mailer.

* Other SMTP, Google / Gmail, Microsoft 365 / Outlook, Zoho Mail and Amazon SES: the SMTP server you configure (smtp.gmail.com, smtp.office365.com, smtp.zoho.com or another Zoho data center, email-smtp.<region>.amazonaws.com, or your own host).
* SendGrid: api.sendgrid.com. [Terms](https://www.twilio.com/en-us/legal/tos), [Privacy](https://www.twilio.com/en-us/legal/privacy)
* Mailgun: api.mailgun.net or api.eu.mailgun.net. [Terms](https://www.mailgun.com/legal/terms/), [Privacy](https://www.mailgun.com/legal/privacy-policy/)
* Postmark: api.postmarkapp.com. [Terms](https://postmarkapp.com/terms-of-service), [Privacy](https://postmarkapp.com/privacy-policy)
* Brevo: api.brevo.com. [Terms](https://www.brevo.com/legal/termsofuse/), [Privacy](https://www.brevo.com/legal/privacypolicy/)
* SparkPost: api.sparkpost.com or api.eu.sparkpost.com. [Terms](https://www.bird.com/legal/terms), [Privacy](https://www.bird.com/legal/privacy)
* Resend: api.resend.com. [Terms](https://resend.com/legal/terms-of-service), [Privacy](https://resend.com/legal/privacy-policy)
* Elastic Email: api.elasticemail.com. [Terms](https://elasticemail.com/resources/usage-policies/terms-of-use), [Privacy](https://elasticemail.com/resources/usage-policies/privacy-policy)
* Google: [Terms](https://policies.google.com/terms), [Privacy](https://policies.google.com/privacy). Microsoft: [Terms](https://www.microsoft.com/servicesagreement), [Privacy](https://privacy.microsoft.com/privacystatement). Zoho: [Terms](https://www.zoho.com/terms.html), [Privacy](https://www.zoho.com/privacy.html). Amazon SES: [Terms](https://aws.amazon.com/service-terms/), [Privacy](https://aws.amazon.com/privacy/)

= SMTPing verification API =

Only when you save an SMTPing API key and keep "Check every recipient with SMTPing before sending" on, each new recipient address is sent to api.smtping.com before the email is sent. Only the address is sent, never the email content. The plugin also reads your remaining credits from the same API to show them in the admin. [Terms](https://smtping.com/terms), [Privacy](https://smtping.com/privacy)

= DNS checks =

The Domain health card reads public SPF, DKIM, DMARC and MX records of your from domain with your server's DNS resolver. No data is sent to SMTPing for this.

= Alerts =

If you enter a webhook URL, failure alerts (site name, email subject, recipients and error message) are sent to that URL, for example hooks.slack.com, discord.com or your Microsoft Teams webhook.

= AI writing assistant =

The "Write with AI" buttons use the WordPress AI Client. The text you typed is sent to the AI provider the site owner connected in Settings > Connectors, under that provider's terms. SMTPing does not call any AI provider itself and stores no AI key.

= Blocklists =

When you run the deliverability check, the sending domain and IP are looked up on public blocklists (Spamhaus, SpamCop, Barracuda, PSBL, Mailspike, SORBS) through DNS queries.

== Screenshots ==

1. Dashboard: emails sent and failed, risky recipients removed, who sends your email, domain health and setup checklist.
2. Sending: choose among 12 SMTP and API mailers, add a backup and a transactional connection, queue, recipient check and alerts.
3. Verify: check any address or a list, and verify the addresses already stored on your site.
4. Email log: every email with its status, mailer and source, details on the right and CSV export.
5. Newsletter campaigns with sent, opens, clicks and unsubscribes.
6. Campaign report: delivery, opens, clicks, risky recipients skipped and most clicked links.
7. Email editor: build newsletters with blocks, subject line and preview text in the side panel.
8. Import subscribers from a CSV file or from your site, with double opt-in and verification first.
9. Connected forms: 31 form plugins feed your lists, each submission checked with SMTPing.
10. Automation builder: a welcome series with emails, waits and conditions.
11. Transactional: branded WordPress emails, a dedicated connection, email controls and smart routing.
12. AI and MCP: AI writing assistant and the abilities available to Claude, ChatGPT, Cursor and other AI agents.

== Changelog ==

= 0.27.1 =
* Security: every SQL query now goes through $wpdb->prepare(), with %i for table and column names and placeholders for IN lists.
* Security: request data is sanitized on read (map_deep, wp_kses with an email HTML allowlist, sanitized $_FILES copies).
* Security: campaign unsubscribe counts are bound to a subscriber who actually received the campaign.

= 0.27.0 =
* AI writing now uses the WordPress AI Client (Settings > Connectors). No AI key is stored by the plugin.
* The built-in MCP endpoint is removed: AI agents connect through the WordPress Abilities API and the official MCP Adapter.
* Upgrading from SMTPing SMTP: the old plugin is no longer deactivated automatically, a notice offers a button instead.
* CSV import uses wp_handle_upload(). Emails with attachments skip the queue and are sent right away.
* Translations are delivered by translate.wordpress.org.
* New email preferences page with list descriptions and "Unsubscribe from all". The unsubscribe link now works in one click, with a Resubscribe button, and adds the person to an automatic "Unsubscribed" list.

= 0.26.0 =
* Email controls, smart routing and a help widget.
* Built-in MCP server and AI writing assistant (OpenAI, Anthropic, Google, xAI).
* Transactional templates and dedicated connection.
* Drag and drop form builder, automations, campaigns and deliverability check.

= 0.4.0 =
* New: alerts by email and webhook (Slack, Discord, Microsoft Teams, JSON) when an email fails, the backup takes over or the queue is stuck.
* New: WP-CLI commands: status, test, queue run, queue retry, log, alert-test.
* New: French translation.

= 0.3.2 =
* New: Test API key button, Save buttons next to each test, automatic save after a successful test.
* Changed: saved passwords and API keys are shown masked with a Remove button.

= 0.3.1 =
* New: Test connection button for SMTP mailers, with a clear reason for each failure.
* Changed: the sending queue is on by default; port and encryption stay in sync.

= 0.3.0 =
* New: dashboard, provider logos, provider filters and search, two-column email log.

= 0.2.0 =
* New: recipient check before sending, email log and bounced addresses.

= 0.1.0 =
* First version: 12 mailers, backup connection, sending queue and test email.

== Upgrade Notice ==

= 0.4.0 =
Adds failure alerts, WP-CLI commands and a French translation.
