The best solution for sending communication emails from PrestaShop is to use an SMTP server from an email account. Using emails, whether paid or free like GMAIL, poses several issues due to sending limitations. These emails are configured for personal use from a mail client, and to combat abuse and reduce the risk of being used, either intentionally or unintentionally, for SPAM activities, the hourly sending limits are very restricted. To make matters worse, many providers (for example, Aruba) use third-party services to verify that sending via SMTP is done from a reliable IP and that the request is not suspicious; this check is done through heuristic analysis, which often leads to false positives. This is done primarily to prevent massive SPAM emails from being sent due to an infected system.

There are also issues related to sending to GMAIL accounts (related to IPv6) that often affect email accounts from Aruba or are related to the SSL certificate, especially when it is a Let's Encrypt, which, although excellent, encounters compatibility issues when used for email.

This is unfortunately a problem for e-commerce sites that receive many orders and/or use modules such as Follow-up or similar to send promotions or invite customers to complete their orders (abandoned carts). For example, if our provider has set the hourly sending limit to 40 emails/hour and the daily maximum to 200 emails sent, any email sent beyond those limits will be blocked by the server and will not reach its destination. Very often, when PrestaShop exceeds the sending limits set by the provider, the provider either blocks the email account for suspected SPAM or blocks the IP from which the request originates.

It is clear that using these emails to send communications to customers from your ecommerce is not a recommended solution.

For this reason, it is necessary to use dedicated emails for the purpose.

Discover the score of your Email

The first operation to perform is to check the score of your email through the service mail-tester.com
To do this, go to BO and navigate to Advanced Settings -> Email
Position yourself in: "Test your email configuration" and enter the email shown by mail-tester in the appropriate field and press: "Send a test email".

Sending limits per hour and daily

Even if the email score is perfect, it can still happen that it does not reach its destination; the main cause is the hourly sending limits. If PrestaShop needs to send 100 emails to invite customers to complete their order and the SMTP server's hourly limit is set to 40 emails/hour, then 60 emails will not reach their destination.

UCEPROTECT and IP ban issues

Even when we have perfectly configured our email server, it can happen that we encounter sending issues to some free accounts, including the Italian ones: libero.it, virgilio.it, alice.it, etc. Often, the problem lies in the fact that our IP is listed on the UCEPROTECT blacklist, or more precisely, some IPs in the class to which our IPv4 belongs have engaged in spam activity. In other words, it is not us directly on the blocked IP list, but due to activities outside our control, we are indirectly affected.

UCEPROTECT is a network that operates with very restrictive principles (which we believe are outdated) and works with filters based on levels.

  • Level 1 concerns the individual IP. It is increasingly common to have a shared IP; in that case, even if we behave well, someone else using the same IP may not. This is why it is very important to use a dedicated IP for the email server.
  • Level 2 concerns the entire class of IPs (about 65,000 addresses for class B).
  • The third level is the most severe, concerning the entire provider.

The most common case is level 2, meaning that one or more of the 65,536 IPs that our IPv4 belongs to has engaged in spam activity. In these cases, sending an email to an address or to the addresses of an email provider may result in it ending up in the recipient's spam folder or being rejected by the mail server. You can check your dedicated IP here: http://www.uceprotect.net/en/rblcheck.php

Even with a large budget, it is currently impossible to obtain an entire class of IPs; the last block of IPv4 was assigned by ICANN in 2011. The only solution is to request (for a fee) that UCEPROTECT add our dedicated IP to the Whitelisted (http://www.whitelisted.org/), thus ensuring that our emails are safe from being blocked due to levels 2 and 3 of the UCEPROTECT filter.

These events are rare, but sometimes cyberattacks and viruses can lead to the unwitting sending of spam or dangerous emails by multiple users of a provider. The likelihood that an IPv4 from the class to which our dedicated IP belongs is reported is very high. There are also services that allow monitoring these events, such as: https://mxtoolbox.com/blacklists.aspx

Author: Loris Modena

SENIOR DEVELOPER

For Ind Loris Modena, owner of Arte e Informatica, started working in the IT sector in 1989 as a system administrator responsible for the maintenance and installation of computer systems. He began programming for the web in 1997, focusing on CGI programming in PERL and later transitioning to programming in PHP and JavaScript. During this time, he became familiar with the Open Source world and the management of Linux servers.

Product added to wishlist