Moodle 5.3 Requirements: PHP 8.3, Database and Server Checklist (2026)

Every Moodle 5.3 requirement in one place: PHP 8.3, database minimums, extensions, max_input_vars, the /public web root, and how to fix the PHP 8.3 error.

MJ
Mihir Jana
·25 November 2026·12 min read
⚡ Quick answer

Moodle 5.3 needs 64-bit PHP 8.3 or later (Moodle's own tests run 8.3 and 8.4), and one of PostgreSQL 17+, MySQL 8.4+, MariaDB 11.4+, SQL Server 2019+ or Aurora MySQL 8.0+. Oracle is not supported. PHP needs the sodium, intl, zip and gd extensions among others, memory_limit of at least 96M and max_input_vars of at least 5000. The web server's document root must point at Moodle's /public folder. You can upgrade to 5.3 directly only from Moodle 4.4 or later.

PHP 8.3+
Minimum PHP for Moodle 5.3 (64-bit)
PostgreSQL 17
Or MySQL 8.4, MariaDB 11.4, SQL Server 2019
5000
Minimum max_input_vars
4.4
Oldest version you can upgrade from directly

Key takeaways

  • PHP 8.3 is the minimum for Moodle 5.3; 8.3 and 8.4 are the versions Moodle tests against.
  • New database minimums in 5.3: PostgreSQL 17 and MariaDB 11.4. MySQL 8.4 and SQL Server 2019 are unchanged from 5.2.
  • Coming from 4.5 LTS? 4.5 blocks PHP 8.4 and 5.3 needs 8.3, so move to PHP 8.3 first, then upgrade Moodle.
  • The 'requires at least PHP 8.3.0' error usually means the CLI, PHP-FPM pool or cron is still using an older PHP binary.
  • Since Moodle 5.1 the web root must point at the /public folder; configure the router and set $CFG->routerconfigured.
  • Sites older than 4.4 must upgrade to 4.4 or 4.5 before going to 5.3.

What are the Moodle 5.3 system requirements?

Every Moodle release ships an environment.xml file that lists the minimum PHP, database and extension versions the installer and upgrader will accept. These are the values for Moodle 5.3 and the four releases before it, taken from that file on the MOODLE_503_STABLE branch:

Requirement4.5 LTS5.05.15.25.3 LTS
PHP (minimum, 64-bit)8.18.28.28.38.3
PostgreSQL1314151617
MySQL8.08.48.48.48.4
MariaDB10.6.710.1110.1110.1111.4
Microsoft SQL Server2017 (14.0)2017 (14.0)2017 (14.0)2019 (15.0)2019 (15.0)
Amazon Aurora MySQLn/a8.08.08.08.0
Oracle19Not supportedNot supportedNot supportedNot supported
Oldest version you can upgrade from4.1.24.2.34.2.34.44.4

Two of these are new in 5.3: PostgreSQL 17 (5.2 accepted 16) and MariaDB 11.4 (5.0 to 5.2 accepted 10.11). PHP 8.3 and MySQL 8.4 were already required by 5.2. If your server met the 5.2 requirements, the database is usually the only thing you need to change.

For support dates and whether to choose the LTS or the six-monthly track, see our post on Moodle 5.0 end of support and Moodle 5.3 LTS. This post is the hands-on server checklist.

Which PHP version does Moodle 5.3 need?

PHP 8.3.0 or later, 64-bit. The minimum is hard-coded in phpminimumversionlib.php, and the environment check refuses 32-bit PHP. Moodle's own automated test runs use PHP 8.3 as the lowest and PHP 8.4 as the highest version for the 5.3 branch (GitHub workflow), so 8.3 and 8.4 are the safe choices. Do not jump to a newer PHP release until Moodle lists it as supported.

There is a sequencing trap if you are coming from 4.5 LTS. Moodle 4.5's environment check blocks PHP 8.4, and 5.3 refuses anything below 8.3. The one version both accept is PHP 8.3. So the clean path is:

  1. On Moodle 4.5, move the server to PHP 8.3 and check the site still works.
  2. Upgrade the database (PostgreSQL 17, MySQL 8.4 or MariaDB 11.4).
  3. Upgrade the Moodle code to 5.3.
  4. Only then, if you want, move PHP to 8.4.

What does "Moodle 5.3 or later requires at least PHP 8.3.0" mean?

This is the exact message Moodle prints when the PHP running it is older than 8.3:

Moodle 5.3 or later requires at least PHP 8.3.0 (currently using version 8.2.x).
Some servers may have multiple PHP versions installed, are you using the correct executable?

The second line is the clue. Most servers that show this error do have PHP 8.3 installed, but one of three things is still pointing at the old version:

  • The command line. You ran php admin/cli/upgrade.php, and php on the path is still 8.1 or 8.2. Check with php -v and which php, then call the 8.3 binary directly, for example /usr/bin/php8.3 admin/cli/upgrade.php.
  • The web server. Nginx or Apache still sends requests to the old PHP-FPM pool. Point the site at the PHP 8.3 FPM socket and restart it.
  • Cron. The Moodle cron entry calls the old binary. Update the crontab line to the PHP 8.3 path, or cron will fail silently after the upgrade.

Remember the PHP extensions too. Each PHP version has its own extension packages, so installing PHP 8.3 does not bring across intl, sodium or zip from 8.2.

Which databases does Moodle 5.3 support?

PostgreSQL 17+, MySQL 8.4+, MariaDB 11.4+, Microsoft SQL Server 2019+ and Amazon Aurora MySQL 8.0+. Oracle support was removed in Moodle 5.0.

For MySQL and MariaDB, the environment check also requires the InnoDB storage engine with the Barracuda file format, innodb_file_per_table set to ON and large index prefixes, which together give full UTF-8 (utf8mb4) support. If you run MariaDB, make sure $CFG->dbtype in config.php is 'mariadb', not 'mysqli'; the check warns you when it is wrong.

A major database upgrade (PostgreSQL 15 or 16 to 17, MariaDB 10.x to 11.4) is a project of its own. Do it as a separate change, on the Moodle version you already run, before you upgrade Moodle itself. That way, if something breaks, you know which change caused it.

Which PHP extensions and settings does Moodle 5.3 need?

TypeWhat Moodle 5.3 checks
Required extensionsiconv, mbstring, curl, openssl, ctype, zip, zlib, gd, simplexml, spl, pcre, dom, xml, xmlreader, intl, json, hash, fileinfo, sodium, filter, plus the driver for your database
Optional extensionstokenizer, soap, exif
Required settingsmemory_limit of at least 96M; max_input_vars of at least 5000; 64-bit PHP
Recommended settingsopcache.enable = 1; file_uploads on; zend.exception_ignore_args = 1
Other checksHTTPS, slash arguments, the database storage engine, Composer dependencies and the router configuration

max_input_vars is the setting most often missed. PHP's default is 1000, and Moodle needs 5000; set it in both the FPM and the CLI php.ini. In practice, give PHP far more than 96M of memory on any site with real users.

What changed on the web server: the /public folder and the router

If you are upgrading from Moodle 5.0 or earlier, this is the change that catches people out. Since Moodle 5.1, the code that should be reachable from the web lives in a public folder inside the Moodle directory, while config.php, admin/cli and the Composer files stay one level up. Your web server's document root must point at /public. If it still points at the Moodle root, the site shows: "The Moodle root directory must not be publicly accessible. Please reconfigure your web server to use the /public directory instead."

Moodle also has a router for newer page addresses. Until your web server sends unknown paths to r.php, those routes work only through /r.php and the Environment page shows "The router is not configured." Once the rewrite rule is in place, set $CFG->routerconfigured = true; in config.php (config-dist.php explains the setting).

If you deploy Moodle from Git rather than a download package, Moodle also checks its Composer dependencies. Run composer install --no-dev --classmap-authoritative in the Moodle root as part of every deployment.

  1. 1
    Check where you are starting from

    Note your Moodle, PHP and database versions. If Moodle is older than 4.4, plan an upgrade to 4.5 first.

  2. 2
    Run the 5.3 environment check

    Go to Site administration > Server > Environment, click Update component, choose 5.3 and list every red row.

  3. 3
    Move PHP to 8.3

    Install PHP 8.3 with all required extensions, then switch the web server, CLI and cron to it. Set max_input_vars to 5000 or more.

  4. 4
    Upgrade the database

    Move to PostgreSQL 17, MySQL 8.4 or MariaDB 11.4 as a separate change, on your current Moodle version, and test.

  5. 5
    Check plugins and the theme

    Confirm every add-on plugin and your theme has a release for Moodle 5.3, and remove the ones you no longer use.

  6. 6
    Prepare the web server for /public

    On staging, point the document root at the public folder, add the r.php rewrite rule and set $CFG->routerconfigured = true.

  7. 7
    Rehearse, then upgrade

    Run the full upgrade on a copy of production, fix what breaks, then repeat it on production in a maintenance window.

⚠

Do not change PHP, the database and Moodle in one night

Each change can break the site on its own. Make the PHP and database changes first, on the Moodle version you already run, so that if something fails you know which change caused it.

Is your server ready for Moodle 5.3? A quick check

CheckHow to checkPass if
Moodle versionSite administration > Notifications (bottom of page)4.4 or later; otherwise go to 4.5 first
PHP version (web)Site administration > Server > PHP info8.3.x or 8.4.x, 64-bit
PHP version (CLI and cron)php -v as the cron userSame version as the web server
Database versionSELECT version(); (PostgreSQL / MySQL / MariaDB)PostgreSQL 17+, MySQL 8.4+, MariaDB 11.4+, SQL Server 2019+
Extensions and settingsSite administration > Server > EnvironmentNo red rows for 5.3
Plugins and themePlugin overview, then each plugin's page on moodle.orgEvery add-on has a version for 5.3
Web rootWeb server configDocument root ends in /public

The Environment page can test your server against releases newer than the one you run. Click Update component to download the latest environment data, then choose 5.3 from the list. It is the fastest way to see every red row before you touch production.

When the server checks pass, follow our step-by-step Moodle 5.3 upgrade guide for the upgrade itself.

Frequently asked questions

What PHP version does Moodle 5.3 require?

PHP 8.3.0 or later, 64-bit. Moodle's own automated tests for the 5.3 branch run on PHP 8.3 and PHP 8.4, so those are the safe versions to use.

Does Moodle 5.3 support PHP 8.4?

Yes. Moodle's tests for the 5.3 branch use PHP 8.4 as the highest version. Moodle 4.5 does not accept PHP 8.4, so if you are upgrading from 4.5, use PHP 8.3 for the upgrade and move to 8.4 afterwards.

Which databases does Moodle 5.3 support?

PostgreSQL 17 or later, MySQL 8.4 or later, MariaDB 11.4 or later, Microsoft SQL Server 2019 or later, and Amazon Aurora MySQL 8.0 or later. Oracle is not supported.

Can I upgrade directly from Moodle 4.1 or 4.3 to 5.3?

No. Moodle 5.3 can only be upgraded to from Moodle 4.4 or later. Upgrade to 4.5 first, then to 5.3.

Why do I get 'Moodle 5.3 or later requires at least PHP 8.3.0'?

The PHP running Moodle is older than 8.3. Usually PHP 8.3 is installed but the command line, the PHP-FPM pool or the cron job still uses the old binary. Check php -v and point each one at PHP 8.3.

What is the /public folder in Moodle 5.1 and later?

Since Moodle 5.1 the web-accessible files live in a public folder inside the Moodle directory. The web server's document root must point at that folder; config.php and the CLI scripts stay one level above it.

What does 'The router is not configured' mean in Moodle?

It means your web server does not yet send Moodle's newer page addresses to r.php. Add the rewrite rule from Moodle's router documentation, then set $CFG->routerconfigured = true in config.php.

How much memory and max_input_vars does Moodle 5.3 need?

The environment check requires memory_limit of at least 96M and max_input_vars of at least 5000. Production sites with many users need much more memory than the minimum.

Sources

Checked on 24 November 2026 in the Moodle source code on GitHub, MOODLE_503_STABLE branch (Moodle 5.3.1+): admin/environment.xml (PHP, database, extension and upgrade-path requirements for 4.5 to 5.3); lib/phpminimumversionlib.php (PHP 8.3 minimum and the error message); the GitHub Actions workflow (PHP versions used in Moodle's own tests); config-dist.php (router setting); and the admin and error language strings for the environment checks and the /public message. Requirements can change in point releases; check the Environment page on your own site before upgrading.

Written by Mihir Jana, founder of edzlms. Connect on LinkedIn.

Want the server work done for you?

Moving PHP, the database and the web root in the right order is where most Moodle 5.3 upgrades go wrong. Our Moodle DevOps support team can audit your server against the 5.3 requirements, plan the sequence and run the upgrade on a staging copy first.

Book a Free Demo →

Tags

MoodleMoodle 5.3Moodle requirementsPHP 8.3Moodle upgrade

See EdzLMS in action.

Book a 45-minute demo tailored to your industry.

Book a Free Demo →