How to integrate SendGrid with your hosting.com Managed WordPress site
This article describes how to integrate the SendGrid email plugin with your hosting.com Managed WordPress site.
This article describes how to integrate a SendGrid account to work with your Managed WordPress site so you can send email.
Although the PHP mail() function is supported for sending notifications (such as password resets) from WordPress, we highly recommend using a service like SendGrid to ensure maximum delivery rates of other email sent from your Managed WordPress site.
There are also very good services like Zoho and Google Workspace, but if you are looking for something more basic that supports custom domains for sending mail, the free package on SendGrid is a solid choice.
Creating and configuring a SendGrid account
The first step is to create and configure a SendGrid account. To do this, follow these steps:
-
Create a SendGrid account. For detailed steps about how to do this, go to How to Create a SendGrid Account.
-
Log in to your SendGrid account.
-
Verify your domain:
- Click Settings, and then click Sender Authentication.
- In the Domain Authentication section, click Authenticate your Domain.
- Select your domain registrar, or click other and type the name manually.
- Type the domain or subdomain that you want to use to send emails.
- Add the CNAME records to your domain's DNS zone.
- Wait about one minute, and then click Verify.
-
Generate an API key:
- Click Settings, and then click API Keys.
- Click Create API Key.
- In the API Key Name text box, type a name for the API key. The name can be whatever you want.
- In the API Key Permissions section, click Full Access.
- Click Create & View.
- Copy the key and save it somewhere safe.
Integrating SendGrid with WordPress
To send email using WordPress, you need an SMTP plugin. The following procedure demonstrates how to configure the WP Mail SMTP plugin to send email using your SendGrid account:
-
Log in to your WordPress site as the administrator.
-
In the left-hand pane, click Plugins.
-
Click Add New.
-
In the Search Plugins text box, type
mail smtp, and then press Enter. -
Locate WP Mail SMTP by WPForms, and then click Install Now.
-
After WordPress finishes installing the plugin, click Activate.
-
In the left-hand pane, click WP Mail SMTP, and then click Settings. The WP Mail SMTP general settings page appears.
-
Under Mail, in the From Email text box, type the e-mail address you want to use as the sender. A very common choice is [email protected] (where example.com represents your own domain name).
-
In the From Name text box, type the name you want to associate with the e-mail address you specified in the previous step.
-
Under Return Path, select the Set the return-path to match the From Email check box.
-
Under Mailer, select Other SMTP.
-
Under Other SMTP, in the SMTP Host text box, type
smtp.sendgrid.net. -
In the SMTP Port text box type
465, and then under Encryption, select SSL. -
Under Authentication, select On.
-
In the SMTP Username text box, type
apikey. -
In the SMTP Password text box, paste the API key from your SendGrid account.
-
Click Save Settings.
Tip
You should test the new configuration to make sure that it works. To do this, follow these steps:
Click the Email Test tab, and then in the Send To text box, type a valid external e-mail address where you can receive a test message.
Click Send Email. You should receive a test message at the e-mail address you specified in the previous step. If you do not receive a message, check the settings you provided, and then try again.
Updated about 4 hours ago
