Now that we have PHPlist installed, and we've made some adjustments to the PHPlist settings, the next step in properly setting up PHPlist is to rate limit the number of emails PHPlist sends out at one time. If this is not properly configured, PHPlist by default will attempt to send all of the emails at one time. On Web Hosting Hub servers, there is a limit on the number of emails that can be sent per hour (250 messages per domain, per hour). This limit is for the protection of our servers and to help prevent Spam. If your mailing list is greater than 250 email addresses, the first 250 messages would be sent, but the remaining messages would not.

Please note, if you have a need to send more than 250 emails per hour, you can submit an Email Limit Exception Request through AMP. Requests are handled on a case by case basis.

Due to the hourly limit on email messages, it's a good idea to allow for other regular emails you may want to send during that time frame. For instance, if you regularly send 5-10 emails per hour, you will want to set the rate limit in PHPlist to 240 or less.

  1. If you are not still logged into your cPanel, begin by logging into your cPanel account.
  2. Click on the File Manager icon under the Files section in your cPanel home screen.
  3. To access the PHPlist configuration file (config.php), navigate to the config directory inside of the directory you installed PHPlist to. Using our example, we installed PHPlist to the directory named newsletter inside our main domain's document root so we need to navigate to public_html/newsletter/config/

    phplist-config-file

  4. Open the config.php for editing by either right clicking and selecting one of the edit options (Edit or Code Editor) or clicking on one of the edit options at the top of the File Manager screen. If you receive an encoding check pop-up window, make sure utf-8 is selected before clicking the Edit button in that window.

    php-list-config-open-edit

  5. The PHPlist configuration file contains a lot of information. While at first glance, it can be easy to get overwhelmed, fortunately we will only be focusing on a few lines that need to be edited. You will want to look for each of the following two lines:

    define("MAILQUEUE_BATCH_SIZE",0);

    define("MAILQUEUE_BATCH_PERIOD",100);

  6. Make sure you locate the lines that do NOT begin with the pound sign (#). In the following example we have highlighted the two lines that you will want to edit:

    phplist-editing-config-file

  7. There's some information you will want to keep in mind when determining BATCH_SIZE and BATCH_PERIOD.

    BATCH_SIZE = the number of emails that will be sent in each batch.

    BATCH_PERIOD = the time to wait (in seconds) between batches. Five minutes (300 seconds) is a good wait period so we will set BATCH_PERIOD to 300.

    We will need to do a little math to determine our BATCH_SIZE. The basic formulas (in seconds) are:

    3660 / BATCH_PERIOD = # of batches
    (60 seconds X 60 minutes = 3660 seconds in an hour)

    Desired Hourly Limit / # of batches = BATCH_SIZE
    (BATCH_SIZE needs to be a whole number, so you may need to round your result up or down)

    For our example, we want to keep the emails sent out by PHPlist to approximately 200 emails per hour and we've chosen a BATCH_PERIOD of 5 minutes (300 seconds).

    3660 / 5 = 12
    200 / 12 = 17 (rounded up from 16.666...)

    So, for our example we will set our BATCH_SIZE and BATCH_PERIOD as follows:

    define("MAILQUEUE_BATCH_SIZE",17);

    define("MAILQUEUE_BATCH_PERIOD",300);

  8. That's it for our changes to the configuration file. In the upper right corner of the edit window, click the Save Changes button and then the Close button.

When we get to our article on sending a message to our mailing list, we'll be able to see our rate limiting in action.

Did you find this article helpful?

We value your feedback!

Why was this article not helpful? (Check all that apply)
The article is too difficult or too technical to follow.
There is a step or detail missing from the instructions.
The information is incorrect or out-of-date.
It does not resolve the question/problem I have.
How did you find this article?
Please tell us how we can improve our Help Center:
Email Address
Optional, but our team may contact you for more information.
Did you find this article helpful?

Post a Comment

Name:
Email Address:
Comment:
Are you a bot?
Submit

Please note: Your name and comment will be displayed, but we will not show your email address.

News / Announcements

Update to SSL Certificates - Certificate Warnings
1969-12-31 11:00 am EST
Hits: 649

Related Questions

Here are a few questions related to this article that our customers have asked:
Ooops! It looks like there are no questions about this page.
Would you like to ask a question about this page? If so, click the button below!

Help Center Search

Current Customers

Email: support@WebHostingHub.com Ticket: Submit a Support Ticket
Call: 877-595-4HUB (4482)
757-416-6627 (Intl.)
Chat: Click To Chat Now

Ask the Community

Get help with your questions from our community of like-minded hosting users and Web Hosting Hub Staff.

Not a Customer?

Get web hosting from a company that is here to help.