Easily Enable EXM

Sending emails via Sitecore shouldn’t be a hassle. Yet, Sitecore documentation starts with a bunch of configurations that doesn’t always provide a smooth walkthrough for developers to enable the Email Experience Manager (EXM) feature for development. In this post, the steps listed below are the easiest path to use Custom SMTP for sending emails for marketing.

Web.config

  • In the root web.config in your server, ensure that the following app settings are defined (which is the default configuration):
<add key="eds:define" value="CustomSMTP" />
<add key="exmEnabled:define" value="yes" />

Ensure License Supports EDS

  • Login to Sitecore as administrator
  • Go to Control Panel and under Administration click Installed Licences. You should see Sitecore.EXM.CustomSMTP included in the license.
CustomSMTP in license
  • If you do not see this, contact the Sitecore Sales Representative to request for a license with this key, then replace your existing one.

Sign Up for a Free SMTP Account

  • I signed up to the free SMTP service called SendInBlue. This is a great SMTP provider which developers can use to send free 300 emails each day. I think 300 is more than enough for daily testing.
  • Upon logging in, click the down caret at the upper right corner of the page and click SMTP & API:
  • Click on the the SMTP Tab. You will see your SMTP settings.
SMTP Settings for your Sitecore EXM

Configure Sitecore EXM Settings for CustomSMTP

  • Sitecore Email Delivery Service (EDS) providers settings are found in a config file called Sitecore.EDS.Providers.CustomSMTP.config under App_Config\Sitecore\EmailExperience\.
  • But for best practices, create a patch file under App_Config\Include\<z.Feature.Overrides (optional)>\ and you can name it as z.Sitecore.EDS.Providers.CustomSTMP.config to follow the convention of the original stock config.
  • Copy and paste your settings from the SMTP tab to the config file:
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/" xmlns:role="http://www.sitecore.net/xmlconfig/role/" xmlns:eds="http://www.sitecore.net/xmlconfig/eds/">
  <sitecore role:require="Standalone or ContentManagement or DedicatedDispatch" eds:require="CustomSmtp">
    <exm>
      <eds>
          <smtpSettings patch:instead="*[@type='Sitecore.EDS.Core.Net.Smtp.SmtpSettings, Sitecore.EDS.Core']" type="Sitecore.EDS.Core.Net.Smtp.SmtpSettings, Sitecore.EDS.Core" singleInstance="true">
              <server>smtp-relay.sendinblue.com</server>
              <port>587</port>
              <userName>{your-login}@gmail.com</userName>
              <password>{master-password}</password>
              <authenticationMethod>PLAIN</authenticationMethod>
              <startTls>true</startTls>
              <proxySettings ref="exm/eds/proxySettings" />
          </smtpSettings>
      </eds>
    </exm>
  </sitecore>
</configuration>
  • Your Sitecore instance will restart after applying changes.

Test EXM CustomSMTP Connectivity

  • After Sitecore restarts, open your Content Editor and click Email root item under /Sitecore/Content.
  • On the ribbon, click Test Connection:
Test CustomSMTP Connection
  • Back on the Sitecore Launchpad, click on the Email Experience Manager:
Launchpad Email Experience Manager
  • Click the Create > Regular email campaign:
Create email to test email sending
  • Under the dialog box Templates section, select Plain text message and give your email campaign a name:
Plain text email
  • Under the General tab, enter your details (e.g. Description, From name, From email, etc.)
General configurations
  • Skip the Recipients tab.
  • In the Message tab, enter your email message:
Email subject and body
  • Under the Review tab, enter your email address to receive test email:
Ready to receive…
  • Click Send. You should now be able to see this beautiful blue bar notification:
Sent!
  • And receive the test email in your inbox:
Received!

Leave a Reply