PHP 8.5 Drops ext-imap: What Mautic Users Need to Know About Composer Install Errors

If you’ve tried installing or updating Mautic with PHP 8.5 recently, you might have hit a nasty snag: a Composer error complaining that the ext-imap extension is missing. You’re not alone. This popped up on the Mautic forums—turns out Mautic 7.2.1 still requires ext-imap, but PHP 8.5 has actually removed that extension entirely.

The core of the issue? Mautic’s installer expects that PHP’s ext-imap is available, which was true for all PHP versions up through 8.4. But starting with PHP 8.5, that extension was stripped out of core PHP. So when Composer checks your environment, it throws an error and halts installation or updates because it thinks you’re missing a hard dependency.

The workaround some users have found is either to downgrade their CLI PHP version to 8.4 temporarily or to run Composer with the “ignore platform requirements” flag to bypass the error. Neither option is perfect—downgrading PHP isn’t ideal if you want to use the latest features or security patches, and ignoring platform requirements can lead to unexpected bugs down the line.

Currently, Mautic 7.2.1 locks in that ext-imap requirement, and there doesn’t seem to be an official patch released yet to address PHP 8.5 compatibility on this front. Some community members have suggested using polyfill libraries like fain182/ext-imap-polyfill, which mimic the old ext-imap functions removed from PHP core, but that’s a workaround rather than a fully baked solution.

In practical terms, if you’re managing a Mautic instance and planning to move up to PHP 8.5, be cautious. The ext-imap issue means you’ll likely run into installation and update headaches unless you stick with PHP 8.4 for now. For marketers who just want their Mautic running smoothly, this will be frustrating, especially since updating PHP is usually a no-brainer to stay secure and performant.

My take? This kind of “dependency lag” is common with open-source projects balancing rapid PHP changes, and it’s a reminder to always check your full stack compatibility before switching major PHP versions. Hopefully, the Mautic devs will update the core-lib dependencies soon or offer an official polyfill. Until then, stay on PHP 8.4 if you want hassle-free Composer installs.

For the full conversation and possible community-supplied patches, check out the original forum thread here.

And if you’d rather avoid this kind of self-hosting drama altogether, Mailertizer’s hosted Mautic platform handles all the backend upgrades and compatibility issues for you, so you can focus on marketing—not fixing PHP conflicts.

Share the Post: