An Introduction to Email Functionality in SugarCRM


In general your database will be the foundation of your business, so it is important that you have a good customer relationship management system (CRM) to effectively nurture and streamline your business. Placing your valuable data into your CRM will allow you follow up regularly with prospects and identify exactly where they are in the sales cycle. The SugarCRM  Email Functionality will allow you to effectively communicate with your prospects from within your CRM system, eliminating the need to use another application to do so.

The information below is an introduction to the SugarCRM email functionality.

Email is divided into two categories, inbound and outbound. There is an assortment of functionality made possible by integrating SugarCRM with an email system. A few examples include:

  • Auto-creating cases
  • Auto-associating notes to cases based on a case macro
  • Handling bounced messages from campaigns
  • Notifying customers of case status changes
  • Notifying users of various events with workflows
  • Sending out marketing email campaigns
  • Sending personal emails to contacts

General Email Terms

When configuring SugarCRM to integrate with your email system it is helpful to be familiar with your email system or have someone on hand who is (e.g. IT).

  • SMTP – Stands for “Simple Mail Transfer Protocol” and is used for outbound email.
  • POP3 – Stands for “Post Office Protocol” and is used for inbound email.
  • IMAP – Stands for “Internet Message Access Protocol” and is also used for inbound email.

When configuring SugarCRM to send email you will need to know:

  1. SMTP server hostname (mail [dot] mydomain [dot] com)
  2. Port
  3. Username
  4. Password

When configuring SugarCRM to receive email you will need to know:

  1. Mail server hostname (mail [dot] mydomain [dot] com)
  2. Mail server protocol (IMAP or POP3)
  3. Port
  4. Username
  5. Password

Outbound Email (SMTP) in SugarCRM

There are two types of outbound email accounts, system and personal.


Only one system outbound email account is allowed and is configured under Admin > Email Settings. Most of the functionality listed above (notifications, campaigns, etc.) uses the system outbound email account.

Note: When configuring the system outbound email settings you will notice the field “Mail Transfer Agent”. Most SugarCRM systems use “SMTP”. The other option, “sendmail”, refers to an application found in many Unix/Linux systems. If you choose to use “sendmail” as your mail transfer agent you are responsible for configuring it on your server. If you do not know what “sendmail” is then you should use “SMTP”.

Note: Sendmail is not supported in Sugar 5.5.1 and later versions.


Personal outbound email accounts can be configured in the Emails module through the Settings window. Only personal emails sent from the Emails module use personal outbound email accounts.

Note: Users can still send emails from the Emails module if they don’t setup a personal outbound email account. SugarCRM will use the system outbound email account by default.

Inbound Email in SugarCRM

SugarCRM provides the following features to manage inbound emails:

  1. Personal accounts
  2. Group accounts
  3. Personal folders
  4. Group folders

The above features provide a variety of ways to interact with emails from IMAP or POP3 email accounts. A quick overview of each is provided below.

Note: POP3 is not supported in Sugar 5.5.1 or later versions.

What is a personal email account?

Personal email accounts are configured by individual users in the Settings menu accessed from the Emails module. They provide a “live” view of an inbound email account. Emails for personal email accounts are not stored in the SugarCRM database (except for a cache of the email headers which is not especially important to know at this time); instead, when a user requests to view an email SugarCRM will open a connection to the configured email server and request the desired email.

Since SugarCRM opens a connection to the email server for each request (Check Mail, view email, etc.) if your email server imposes a connection limit and you have several users with personal accounts, SugarCRM may exceed this connection limit. When a connection limit is exceeded the email server will begin to block requests which can lead to unusual behavior such as:

  • Email bodies not returned when selecting an individual email
  • Check mail operations timing out
  • Emails not deleting successfully from the email server

To resolve these types of issues you will need to ask your email service provider to lift any connection limits or use one of the group mail options described below.

Note: This is the only email account type that responds to the “Check Mail” button found in the Emails module.

What would a personal email account be used for?

Personal email accounts can be used by individual users to view their personal email accounts within SugarCRM. Due to connection limits imposed by many email servers, however, this type of email account is not often used. Email integration with SugarCRM is better suited for group emails, for example a support organization may access their “support” inbox through SugarCRM.

What is a group email account?

A group account is useful when multiple users need to access a single email inbox.  For instructions on setting up a group account refer to the Sugar documentation for the Sugar edition that you use.  Group accounts are identical to personal accounts except for the following:

  1. The “Check Mail” button does not work for group accounts. The check mail process is run by a scheduler. The default scheduler, “Check Inbound Mailboxes”, is provided which will check all configured email accounts. You will need to setup cron for this to work.
  2. Multiple users can access a group email account.  In Sugar Enterprise and Professional, access to group email accounts is controlled by the value of the field “Assign To Team” which is set during the configuration of the email account. For example, if a group email account is assigned to the Global team than all users will have access to that email account.

Note: Since the check mail process is run by a scheduler the number of connections to the email server from SugarCRM is reduced as compared to a personal email account. However, the connection limit issue mentioned earlier may still apply since a connection is used by each user for each viewed email.

What would a group email account be used for?

In addition to shared inboxes, group accounts can also be used for bounce handling mailboxes in email campaigns.

What is a personal folder?

For each user a default set of personal folders is provided; these folders are visible when a user navigates to the Emails module.  New personal folders can be created by clicking the right mouse button on an existing folder (e.g. My Email) and choosing Create Folder. Users can archive emails by dragging them from personal or group accounts into a folder.


Note: Personal folders are reliant on a user’s private team to function properly. It is important to maintain a user’s association with their respective private team for this feature to function properly.

What is a group folder?

A folder is a collection point for imported emails that have been pulled from an email server and downloaded to a SugarCRM database. Emails are imported by moving them from personal or group email accounts into a folder. As we’ll discuss in a minute the process of importing emails can be automated.

Note: The Group folder feature is not supported in Sugar 5.5.1 or later versions..

Group folders are folders that can be accessed by multiple users. Only admin users can create group folders. When group folders are created they are assigned to a team (in Enterprise and Professional) to control which users have access to the folder. For example, a group folder assigned to the Global team will be accessible to all users. In Sugar Community Edition and Sugar Express, administrators can distribute emails from the Group folder to one or more users for action.

Users can control what folders are visible in the Email UI through the Settings menu in the Folders tab.

Folder management for the Email UI

So far this is pretty boring stuff. The cool part of group folders is the ability to set up automated importing of emails into group folders. During the definition of a group account (Admin > Inbound Email), admins can set the field “Assign To Group Folder” to a group folder. When SugarCRM runs the check mail process (run by a scheduler) emails are pulled from the email account and automatically archived into the chosen group folder. Along with the automated importing of emails, admins can also configure SugarCRM to automatically create cases from incoming emails. More details regarding this functionality are available here.

Note: When a group account is associated to a group folder, users will no longer be able to access this account under Emails > Settings > Mail Accounts. Instead, the account is hidden and users access emails from the group folder.

When emails are viewed from a group folder they are pulled from the SugarCRM database rather than from the email server. The only connection opened to the email server by SugarCRM is the one opened during the check mail process. This provides a workaround if you run into connection limit issues (discussed above) with your email service provider.

What would a group folder be used for?

Group folders can be used for shared inboxes, bounce handling mailboxes, and case auto-creation.

Should I use a group account or a group folder?

This will depend on the capabilities of your SugarCRM server and email server. Using a group account will tax your email server more than a group folder, however, it will limit the number of emails imported into the SugarCRM database. It seems most users have the best experience with group folders; accessing emails from the database, instead of the email server, seems to be more reliable.

You should discuss these options with your database administrator and email service provider to make the best decision for your individual situation.

Troubleshooting Inbound Emails

Before concluding this article,  let’s briefly discuss troubleshooting problematic inbound email accounts. For those scenarios where “Test Settings” is failing the following steps should help identify any problems:

These steps assume you have entered all required fields and when pressing “Test Settings” a pop-up window appears informing you that the connection attempt has failed.

  1. Leave the email settings window open
  2. In a new tab or window set the logging level to debug as described here
  3. Switch back to the email settings window
  4. Click Test Settings again
  5. Retrieve the sugarcrm.log file (as described in the article referenced earlier)
  6. Look for the following statements:
    Thu Jun 18 14:17:55 2009 [240][1][DEBUG] ---------------STARTING FINDOPTIMUMS LOOP----------------
    Thu Jun 18 14:17:55 2009 [240][1][DEBUG] 1: I-E testing string: {}INBOX
    Thu Jun 18 14:17:55 2009 [240][1][DEBUG] 1: I-E failed using [{}INBOX] - error: Can't do secure authentication with this server
    Thu Jun 18 14:17:55 2009 [240][1][DEBUG] 1: I-E clearing error and alert stacks.
    Thu Jun 18 14:17:55 2009 [240][1][DEBUG] 2: I-E testing string: {}INBOX
    Thu Jun 18 14:17:56 2009 [240][1][DEBUG] 2: I-E found good connect using [{}INBOX]
    Thu Jun 18 14:17:56 2009 [240][1][DEBUG] 2: I-E clearing error and alert stacks.
    Thu Jun 18 14:17:56 2009 [240][1][DEBUG] ---------------end FINDOPTIMUMS LOOP----------------


A quick recap:

  • Emails are accessed from email servers by personal or group accounts
  • Emails are imported into SugarCRM by placing them in folders
  • Admins can automate the process of importing emails from group accounts into group folders
  • Admins can auto-create cases from emails imported from group accounts into group folders
This information was provided by SugarCRM.
For more information please call us at 818 227 5130