How to enable the intl extension to use CakePHP or Magento on mac

Home > Blog > Learning > How to enable the intl extension to use CakePHP or Magento on mac


When you first install CakePHP3 or Magento, I guess “enable the intl extension” is the first hurdle. It’s been a while since I first dealt with this problem, but I remember it was complicated a little. Today, I’m going to introduce some solutions that worked for me. The Terminal command might intimidate you, but don’t worry! I’m going to share every step I took.


macOS Catalina MAMP 5.7 CakePHP3 / Magento

Let’s get started!

Step1: Open Terminal and Check if Homebrew is installed

Users-MacBook:~ user$ which brew If it returns: /usr/local/bin/brew → Step3 not found → Step2

Step2: Install Homebrew

Access to, then copy and Paste an install command.Users-MacBook:~ user$ Copy & Paste Here

Step3: Check PHP path

Users-MacBook:~ user$ which php If it returns: /usr/bin/php → Step4 /Applications/MAMP/bin/php/php7.2.7/bin → Step5

Step4: Change Path

Users-MacBook:~ user$ PATH=”/Applications/MAMP/bin/php/php7.2.7/bin:${PATH}”

Step5: Install icu4c

Users-MacBook:~ user$ brew install icu4c

Step6: Install intl

Users-MacBook:~ user$ sudo pecl update-channels Users-MacBook:~ user$ sudo pecl install intl If you get “Cannot find autoconf” message:Users-MacBook:~ user$ brew install autoconf Succeed → Step7 Failed → Skip Step7

Step7: Activate intl & Restart XAMPP

Open /Applications/MAMP/bin/php/php7.2.7/conf/php.ini , and find; ↓   // Remove semicolon Then, restart MAPP.

STEP8: Check the installation

There are two ways to check if our intl installation is success. First is using the following command
$ php -m | grep intl


Leave a Reply

Your email address will not be published. Required fields are marked *