What is WordPress SMTP, how to configure it, and recommended plugins

Nov 13, 2026 / 7 min Read
What is WordPress SMTP, how to configure it, and recommended plugins

WordPress SMTP is a setup that sends your site’s emails, such as contact form notifications and password resets, through an authenticated mail server instead of the PHP mail() function WordPress uses by default. Combined with SPF, DKIM, and DMARC records on your domain, it makes your messages much more likely to reach the inbox.

To set it up, create a mailbox on your domain, install an SMTP plugin like WP Mail SMTP, enter your mail server’s SMTP details, and send a test email. You’ll also learn how to fix common sending errors, which SMTP plugins to consider, and when a dedicated mail service like Brevo or SendGrid makes more sense.

What is WordPress SMTP?

WordPress SMTP means configuring your WordPress site to send email over the Simple Mail Transfer Protocol (SMTP) by logging in to a real mail server, instead of handing messages to the web server’s PHP mail() function. SMTP is the standard protocol for sending email, but WordPress doesn’t use an SMTP server by default.

Out of the box, WordPress sends email through its wp_mail() function, which tells the PHPMailer library to use PHP mail() and the server’s local mail software. An SMTP plugin changes that connection, so contact forms, password resets, and store notifications go through your mailbox provider or a mail service like Brevo.

Why should you use SMTP for WordPress?

SMTP makes WordPress emails more reliable because they’re sent from an authenticated mailbox on your domain, which recipient servers can verify. Emails sent with PHP mail() often leave from a shared web server that your domain doesn’t authorize, so providers like Gmail and Outlook are more likely to reject them or mark them as spam.

Recipient servers check three DNS records on your sending domain:

  • Sender Policy Framework (SPF) lists the servers allowed to send email for your domain.
  • DomainKeys Identified Mail (DKIM) records add a digital signature proving the message came from your domain and wasn’t altered.
  • Domain-based Message Authentication, Reporting, and Conformance (DMARC) tells recipients what to do with messages that fail SPF or DKIM checks.

These records aren’t part of SMTP itself, but SMTP lets you send through a mail server your records already authorize. If you use Hostinger Mail and need your own signing key, follow the steps for adding a custom DKIM record for Hostinger Email. Authenticated sending also makes it harder for attackers to spoof your domain, because recipients can reject forged messages that fail these checks.

Some hosts also limit or disable PHP mail() to prevent spam. In that case, an SMTP plugin is the standard way to send WordPress email, as long as your host allows outgoing connections on SMTP ports such as 465 or 587.

How to set up SMTP in WordPress

You can set up WordPress SMTP in four steps: create a mailbox on your domain, connect it with an SMTP plugin, send a test email, and fix any errors. The steps below use Hostinger Mail and the WP Mail SMTP plugin, but the process works with any email provider that gives you SMTP details.

A free domain and free mailboxes for the first year come with every Hostinger WordPress web hosting plan, so you can create a branded address like name@domain.tld without a separate email subscription.

1. Create a mailbox on your domain

Your site needs a mailbox to send from, plus that mailbox’s SMTP settings. Before you configure WordPress, create your email account on your domain and note the outgoing server details. With Hostinger Mail, follow these steps:

  1. Go to Hostinger dashboard → Emails. If this is your first mailbox, activate the free email trial included with your plan and select your domain.
  2. Click Mailboxes next to your domain, then click Add mailboxes.
  3. Enter the email name and password, then click Create.
The email account setup menu in hPanel
  1. Click Manage next to your domain and open Connect Apps & Devices in the sidebar.
  2. Note the SMTP (outgoing) settings: host smtp.hostinger.com, encryption SSL, and port 465.

If SSL on port 465 fails, Hostinger Mail also accepts TLS (STARTTLS) on port 587. Your SMTP username is the full email address, and the password is the mailbox password you just set. To change the password or add aliases later, see how to create and manage Hostinger Mail mailboxes.

Hostinger Agent in WordPress is available on selected Hostinger plans and requires the Hostinger AI plugin. If your site has it, you can look up these details without leaving WordPress. Open Hostinger Agent in WordPress admin by selecting Hostinger in the WordPress sidebar and clicking Agent in the bottom-right corner, log in with your Hostinger account, and ask:

What are the SMTP settings for name@domain.tld?

Hostinger Agent returns the SMTP host, port, encryption, and username for that account, plus port 587 with TLS as a fallback if SSL on port 465 fails.

Hostinger Agent listing the SMTP server, port, and encryption for a Hostinger email account in WordPress admin

2. Install and configure WordPress SMTP Plugin

To configure SMTP, use the WP Mail SMTP plugin. After launching your WordPress website, follow these steps:

  1. Open your WordPress admin dashboard.
  2. Go to Plugins → Add New Plugin, search for WP Mail SMTP, then install and activate it. If you’re new to this, learn how to install WordPress plugins.
  3. When the Setup Wizard opens, click Go back to the Dashboard to configure the plugin manually.
  4. On the WP Mail SMTP settings page, scroll to Primary Connection and enter your mailbox address in From Email.
  5. Enter the From Name, which recipients see as the sender.
WP Mail SMTP's primary connection settings
  1. Optionally, enable Return Path so bounce notifications go to your From Email address.
  2. Under Mailer, select Other SMTP, then enter the SMTP host, encryption, and port from step 1
Mailer selection in WP Mail SMTP plugin
  1. Turn Authentication on. If an Auto TLS toggle appears, leave it on.
  2. Enter your full email address as the SMTP Username and your existing mailbox password as the SMTP Password.
  3. Click Save Settings.

Pro Tip

Save the SMTP password and username in the wp-config.php file to improve security.

Remember that the steps can slightly differ if you use a different plugin.

If you purchase the WP Mail SMTP Elite plan, you’ll get a free White Glove setup service that handles the configuration process.

Want to see this setup in action? This video walks through configuring WordPress SMTP using Hostinger Mail.

Subscribe For more educational videos! Hostinger Academy

3. Send a test email

Send a test email to check whether the SMTP service works properly. Here’s how to do it using the WP Mail SMTP plugin:

  1. In the WordPress dashboard, go to WP Mail SMTP → Tools and open the Email Test tab.
  2. In Send To, enter any email address whose inbox you can access.
  3. Enable HTML and click Send Email.

The plugin should confirm that it sent the email successfully. Otherwise, check the destination address and the WordPress SMTP settings.

WP Mail SMTP confirms the test email was successful

If you use the premium WP Mail SMTP plugin, enable the Alerts and Email Log settings to track whether you sent the messages properly.

4. Troubleshoot sending issues

If you encounter an issue when sending an SMTP email, check out some of the most common causes and their solutions:

  • Incorrect WP Mail SMTP settings. Make sure WP Mail SMTP uses the correct SMTP host, port, encryption method, username, and password.
  • Mail server issue. Temporarily switch to another SMTP server, like Gmail, to check whether the problem is with your provider.
  • Web hosting configuration. Some hosts block outgoing SMTP connections, so confirm that your host allows the port your mail server uses and check whether SMTP port 587 is open if you use TLS.
  • Domain authentication. If test emails arrive in spam, make sure your sending domain has SPF, DKIM, and DMARC records that authorize your mail provider.

If you use Hostinger Mail and your emails still fail or land in spam, ask Hostinger Agent in WordPress admin to check the DNS records on your sending domain:

What DNS records does domain.tld have?

Recipient servers check the SPF and DKIM records in that list before trusting your SMTP emails. If the problem continues, ask Hostinger Agent to connect you with our Customer Success team, then click Wait for a human review to queue your request for a specialist.

Hostinger Agent listing the DNS records of a domain from WordPress admin

Important

Important! Connecting to a Google Workspace email account requires different information from SMTP. You’ll need a client ID, a secret key, and an authorized redirect URI.

Use the WP Mail SMTP plugin’s built-in debugging feature to simplify troubleshooting. To access it, go to your WordPress sidebar → WP Mail SMTP → Tools → Debug Events.

WP Mail SMTP's event debugger

If you use its White Glove Setup service, the plugin developer will troubleshoot the issues and ensure your SMTP server settings are properly configured.

What are the best WordPress SMTP plugins and mail services?

WP Mail SMTP is the best choice for most WordPress sites, but FluentSMTP, Post SMTP, and Easy WP SMTP are strong alternatives for specific needs. An SMTP plugin connects WordPress to a mail server, while an SMTP mail service is the server that sends and tracks your messages. A mailbox on your domain handles everyday site emails, and a dedicated service makes sense for high volumes or detailed delivery reports.

These SMTP plugins connect WordPress to your mailbox or mail service:

  • WP Mail SMTP: best for most sites. WP Mail SMTP is the plugin used in this tutorial. Its free version connects WordPress to any SMTP server or popular mail service, while WP Mail SMTP Pro adds email logs, delivery reports, backup connections, and failure alerts.
  • FluentSMTP: best free option. FluentSMTP is completely free and connects to services like Amazon SES, Gmail, and Brevo, as well as any SMTP server. It includes email logs, routing across multiple connections, and a fallback connection when the primary one fails.
  • Post SMTP: best for failure alerts. Post SMTP lets you set a backup mailer for when the main one fails. It sends instant alerts by email, Slack, SMS, or push notification whenever a message isn’t delivered.
  • Easy WP SMTP: best for simple setups. Easy WP SMTP includes a setup wizard, and its free version works with any SMTP server and services like Brevo, Mailgun, and SendGrid. Gmail, Google Workspace, and Microsoft 365 integrations require Easy WP SMTP Pro.

These SMTP mail services send your WordPress emails through their own infrastructure, connected through one of the plugins above:

  • Brevo: best for combining site emails with marketing. Brevo is an email marketing platform with an SMTP relay, a free plan with a daily sending cap, and tools like automation workflows, A/B testing, and contact management. Pair it with a custom WordPress contact form to grow your subscriber list.
  • SendGrid: best for high-volume sending. Twilio SendGrid is an email delivery platform built for sites that send large volumes of transactional email. Twilio retired SendGrid’s free plans in 2025, so plan for a paid subscription. To connect it, create an API key in your SendGrid account and enter it in a plugin that supports SendGrid, such as FluentSMTP or Easy WP SMTP.

Next steps after setting up WordPress SMTP

Check that your site’s real emails arrive, not just the test message. Submit your contact form, request a password reset, and, if you run a store, place a test order, then confirm each message lands in the inbox with the correct From name and address.

Next, secure the connection. If your Hostinger Mail plan supports app passwords, generate one for WP Mail SMTP instead of using your main mailbox password, so you can revoke the plugin’s access without changing your login. Whenever you change the password the plugin uses, update the SMTP Password field right away, or your site will stop sending email.

Keep an eye on delivery over time. Turn on email logging if your plugin offers it, such as in FluentSMTP or WP Mail SMTP Pro, and review failed messages after plugin updates or DNS changes. If you haven’t published a DMARC record yet, start with a monitoring-only policy and review the reports before telling recipients to quarantine or reject failing messages.

Plan for sending volume as your site grows. Each Hostinger Mail mailbox has a daily sending limit that depends on your email plan, so move newsletters and other bulk email to a service like Brevo or SendGrid, and keep your mailbox for transactional messages. Authorize each new service in your SPF and DKIM records before you start sending from it.

If messages still bounce or land in spam, work through these common causes of emails not sending.

This article is a localized version of What is WordPress SMTP, how to configure it, and recommended plugins, originally published in English.

All of the tutorial content on this website is subject to Hostinger's rigorous editorial standards and values.

Aris is a Content Writer specializing in Linux and WordPress development. He has a passion for networking, front-end web development, and server administration. By combining his IT and writing experience, Aris creates content that helps people easily understand complex technical topics to start their online journey. Follow him on LinkedIn.

Marco Chiesi is the Head of WordPress at Hostinger, with over 20 years of experience as a software engineer in the web industry. He specializes in open-source technologies and the WordPress ecosystem, where he has contributed in different areas: Plugin Developer (with over 10 million downloads), WordCamp speaker and organizer, Meetup organizer, Translator, and Core Contributor. He is passionate about leading his team to create innovative solutions for Hostinger's web hosting product, which hosts over 5 million WordPress installations. Follow him on LinkedIn.

Trusted by 4+ million website owners worldwide

See our 74,073 reviews on Trustpilot