Send email from your SMTP account with Azure Logic Apps

With Azure Logic Apps and the Simple Mail Transfer Protocol (SMTP) connector, you can create automated tasks and workflows that send email from your SMTP account. You can also have other actions use the output from SMTP actions. For example, after your SMTP sends an email, you can notify your team in Slack with the Slack connector. If you're new to logic apps, review What is Azure Logic Apps?

Prerequisites

  • An Azure subscription. If you don't have an Azure subscription, sign up for a free Azure account.

  • Your SMTP account and user credentials

    Your credentials authorize your logic app to create a connection and access your SMTP account.

  • Basic knowledge about how to create logic apps

  • The logic app where you want to access your SMTP account. To use an SMTP action, start your logic app with a trigger, such as a Salesforce trigger, if you have a Salesforce account.

    For example, you can start your logic app with the When a record is created Salesforce trigger. This trigger fires each time that a new record, such as a lead, is created in Salesforce. You can then follow this trigger with the SMTP Send Email action. That way, when the new record is created, your logic app sends an email from your SMTP account about the new record.

Connect to SMTP

When you use a trigger or action that accesses a service for the first time, the Logic Apps Designer prompts you to create a connection to that service. You can then provide the necessary connection information directly from your logic app inside the designer.

  1. Sign in to the Azure portal, and open your logic app in Logic App Designer, if not open already.

  2. Under the last step where you want to add an SMTP action, choose New step.

    To add an action between steps, move your pointer over the arrow between steps. Choose the plus sign (+) that appears, and then select Add an action.

  3. In the search box, enter "smtp" as your filter. Under the actions list, select the action you want.

  4. When prompted, provide this connection information:

    Property Required Description
    Connection Name Yes A name for the connection to your SMTP server
    SMTP Server Address Yes The address for your SMTP server
    User Name Yes Your username for your SMTP account
    Password Yes Your password for your SMTP account
    SMTP Server Port No A specific port on your SMTP server you want to use
    Enable SSL? No Turn on or turn off SSL encryption.
  5. Provide the necessary details for your selected action.

  6. Save your logic app or continue building your logic app's workflow.

Connector reference

For technical details about triggers, actions, and limits, which are described by the connector's OpenAPI (formerly Swagger) description, review the connector's reference page.

Get support

Next steps