SMTP for Contact Form 7 source code

By Erik, on WordPress.org since 2022. 1,000+ active installs.

Browse code Download zip

WordPress uses PHPMailer to send mail from with your local mail server, but it can happen that your mail were not accepted by mail providers… This can happen for several reasons, sometimes because the mail server is... Below is its source code for every one of its 5 releases, what changed in the latest one, and how often it ships.

What changed in 1.1.2

Released Jun 22, 2026, 1 month after 1.1.1
  • New: Added an optional “Tenant ID” setting for the Office 365 provider to support single-tenant Azure applications, preventing AADSTS50194 endpoint errors.
  • Fix: Resolved a critical issue with the Office 365 OAuth2 flow where the user email was not stored, causing XOAUTH2 mail delivery to fail. The plugin now properly extracts identity claims directly from the JWT access token.
  • Fix: Fixed a bug where non-CF7 WordPress emails were completely dropped when the “SMTP Mode” was set to “Contact Form 7 Only”. Normal emails will now correctly bypass the SMTP transport.
  • Fix: Resolved an issue in the settings validation where newly entered OAuth2 credentials were unintentionally wiped if the user saved them while simultaneously changing the authentication method.
  • Fix: Patched a silent failure in the OAuth2 REST API endpoint that previously returned a success status with a null URL instead of a proper error message when client credentials were unreadable or missing.
  • Refactor: Cleaned up wp-config.php constant definitions. Removed unnecessary hardcoded constants for non-sensitive settings (Host, Port, From Mail, etc.) and introduced dedicated security constants for CF7_SMTP_OAUTH2_CLIENT_ID and CF7_SMTP_OAUTH2_CLIENT_SECRET.

13 files changed since 1.1.1: 12 modified, 1 added, 0 removed.

And 3 more.

Compare 1.1.1 with 1.1.2

Release history

5 releases since December 2025
  1. 1.1.2 Jun 22, 2026 New: Added an optional “Tenant ID” setting for the Office 365 provider to support single-tenant Azure applications, preventing AADSTS50194 endpoint errors.
  2. 1.1.1 Apr 28, 2026 Security: Implemented AES-256-GCM encryption for sensitive data with enhanced key and IV handling.
  3. 1.1.0 Mar 24, 2026 New: Added OAuth2 authentication support for Microsoft Office 365.
  4. 1.0.0 Dec 10, 2025 Cleaner code, updated dependencies
  5. 0.0.1 Dec 10, 2025 First Release
Full SMTP for Contact Form 7 changelog with diffs

Source of 1.1.2

236 files
Browse all SMTP for Contact Form 7 1.1.2 files Browse trunk