Send us a message and we'll get back to you shortly.
Moodle 5.3 LTS on a Hetzner Cloud server with Ubuntu 24.04: the requirements, every command, server prices read on November 17, 2026, and what maintenance takes.
Short answer (November 17, 2026): Moodle 5.3 LTS installs on a Hetzner Cloud server running Ubuntu 24.04 with Apache, PHP 8.3 and MariaDB 11.4, in the six steps below. Maintained by Cubite (cubite.io), which runs managed Open edX from $1,260 a month and managed Moodle from $690 a month.
Disclosure: Cubite sells managed Moodle, the alternative this guide ends with, is not a Moodle Certified Partner, and publishes this guide. Every Moodle, Ubuntu, MariaDB, Certbot, Hetzner and other vendor fact below comes from that vendor's own documentation or pages, read on November 17, 2026; the sources are listed at the end.
Supported versions (moodledev.io, November 17, 2026): Moodle 5.3 LTS was released on October 5, 2026, and 5.3.1 followed on November 12, 2026. It gets general bug fixes until October 4, 2027 and security fixes until October 1, 2029. Moodle 5.2 gets security fixes until October 4, 2027, Moodle 5.1 until April 19, 2027 and Moodle 4.5 LTS until October 4, 2027. If you already run an older release, see how to upgrade to Moodle 5.3 LTS instead.
This guide has two parts: the commands that install Moodle 5.3 LTS on your own server, and what it takes to keep that server running afterwards. Each command was checked against the documentation named beside it, and on November 17, 2026 the commands of steps 2, 3, 4 and 6 were run in order in a clean Ubuntu 24.04 container: Moodle 5.3.1+ installed on PHP 8.3.6 and MariaDB 11.4.14, and Moodle's status check reported the web server and the router as correctly configured. That run was not on a Hetzner server and used Moodle's command-line installer; step 1, the certificate, and the firewall and SSH settings in step 5 were checked against documentation only. Run the whole sequence on a test server before you rely on it. This guide is also available in Spanish, for Moodle 5.2: Instalar Moodle 5.2 en Hetzner Cloud.
Moodle is open-source software under the GPL that you can run on your own server. Self-hosting makes sense when you want:
Moodle 5.3 is a long-term support release, so a server built on it today gets security fixes until October 1, 2029. Its database requirements are higher than Moodle 5.2's, so install guides written for 5.2 or earlier need changes; the table in the next section shows which.
Moodle 5.3 was released on October 5, 2026. From its release notes, the changes that matter for a new site:
The requirements changed too, and this is the part that matters for self-hosting:
| Component | Moodle 5.2 | Moodle 5.3 LTS |
|---|---|---|
| PHP | 8.3.0 minimum, 8.4.x supported, 64-bit only | 8.3.0 minimum, 8.4.x supported, 64-bit only |
| MariaDB | 10.11.0 | 11.4.0 (raised in 5.3) |
| MySQL | 8.4 | 8.4 |
| PostgreSQL | 16 | 17 (raised in 5.3) |
| Upgrade from | Moodle 4.4 or later | Moodle 4.4 or later |
The MariaDB line is the one that catches people out. Ubuntu 24.04 installs MariaDB 10.11 from its own packages, and Moodle's own Ubuntu guide warns that with it the installation will stop at the environment check. Ubuntu 24.04's MySQL 8.0 and PostgreSQL 16 packages are below Moodle 5.3's minimums as well. Step 3 below installs MariaDB 11.4 from MariaDB's repository instead.
Software, from the 5.3 release notes and the requirements file in Moodle's code:
public directory, a change that arrived in Moodle 5.1Hardware. Moodle's install page lists 200 MB of disk for the code plus whatever your content needs (it calls 5 GB a realistic minimum), a 1 GHz processor as the minimum with a 2 GHz dual core or more recommended, and 512 MB of memory as the minimum with 1 GB or more recommended, adding that 8 GB plus is likely on a large production server. This guide uses a server with 4 vCPUs, 8 GB of memory and 160 GB of disk, so the database, PHP and uploaded course files fit on one machine. Size your own server from your content and a load test.
Hetzner sells cloud servers in three plans: Cost-Optimized and Regular Performance, which share CPU cores, and General Purpose, which has dedicated cores. The prices below are from Hetzner's own plan pages on November 17, 2026, in euros per month excluding VAT, with one IPv4 address included. Hetzner prices each server by location and bills by the hour up to the monthly price. If you are still choosing between self-hosting, managed hosting and MoodleCloud, our Moodle hosting guide compares the three.
| Server type | vCPUs | Memory | Disk | Price per month, excluding VAT | On Hetzner's page that day |
|---|---|---|---|---|---|
| CX23 (Cost-Optimized, shared) | 2 | 4 GB | 40 GB | EUR 5.99 | Marked not available |
| CX33 (Cost-Optimized, shared) | 4 | 8 GB | 80 GB | EUR 8.99 | Marked not available |
| CPX22 (Regular Performance, shared) | 2 | 4 GB | 80 GB | EUR 16.99 in Helsinki, EUR 19.99 in Nuremberg | Listed |
| CPX32 (Regular Performance, shared) | 4 | 8 GB | 160 GB | EUR 30.49 in Helsinki, EUR 35.99 in Nuremberg | Listed |
| CPX42 (Regular Performance, shared) | 8 | 16 GB | 320 GB | EUR 59.49 in Helsinki, EUR 69.99 in Nuremberg | Listed |
| CCX13 (General Purpose, dedicated) | 2 | 8 GB | 80 GB | EUR 36.99 in Helsinki, EUR 43.49 in Nuremberg | Listed |
| CCX23 (General Purpose, dedicated) | 4 | 16 GB | 160 GB | EUR 73.49 in Helsinki, EUR 86.49 in Nuremberg | Listed |
Hetzner's pages say that cloud servers in its EU locations include at least 20 TB of traffic a month, that its cloud firewalls come without additional costs, and that daily backups are an add-on with seven backup slots per server. On November 17, 2026, the Cost-Optimized page marked every CX type as not available and said the number of available servers in that plan is limited, so the steps below use CPX32 from the Regular Performance page. Hetzner's locations for cloud servers are Falkenstein and Nuremberg in Germany, Helsinki in Finland, Ashburn and Hillsboro in the United States, and Singapore.
| Provider | Server | Listed price | Included transfer |
|---|---|---|---|
| Hetzner CPX32 | 4 vCPUs, 8 GB of memory, 160 GB of disk | EUR 30.49 a month in Helsinki, EUR 35.99 in Nuremberg, excluding VAT | At least 20 TB in EU locations |
| DigitalOcean Basic Droplet | 4 vCPUs, 8 GiB of memory, 160 GiB of disk | $48.00 a month | 5,000 GiB |
| AWS Lightsail (Linux, with a public IPv4 address) | 2 vCPUs, 8 GB of memory, 160 GB of disk | $44 a month | 5 TB |
Each price is from the provider's own pricing page on November 17, 2026 (Hetzner, DigitalOcean, AWS Lightsail), in the currency it lists. The three are not identical machines, so read the table as a starting point. If you would rather not run a server at all, Cubite's managed Moodle starts at $690 a month for up to 500 concurrent learners: see managed Moodle hosting and support.
These commands set up Moodle 5.3 LTS on a Hetzner Cloud server running Ubuntu 24.04 LTS, with Apache, PHP 8.3 from Ubuntu's own packages and MariaDB 11.4 from MariaDB's repository.
What you need before you start:
When the settings are right, click Create & Buy now. Note the server's IP address and point your domain's A record at it.
Connect over SSH with ssh root@your-server-ip and run:
Ubuntu 24.04 ships PHP 8.3 in its own archive (packages.ubuntu.com), so no extra PHP repository is needed. From this list Moodle requires curl, gd, intl, mbstring, xml and zip, plus the MySQL driver that MariaDB uses; soap is recommended, and ldap, xmlrpc, pspell and apcu are optional extras. There is no php8.3-sodium package to install: the sodium extension that Moodle requires is built into Ubuntu's PHP 8.3 itself. The a2enmod line switches on the modules that pass requests to PHP-FPM (proxy_fcgi and setenvif) and the rewrite module, the same three that Moodle's Ubuntu guide enables. Ubuntu's PHP-FPM package also suggests a2enconf php8.3-fpm; this guide leaves it out, because that stock setting sends every address ending in .php to PHP-FPM, even when no such file exists, and Moodle's router has to receive those. Step 4 connects PHP inside the virtual host instead.
Now set PHP's limits for Moodle:
Moodle's release notes require max_input_vars of 5000 or more, and Moodle's PHP page asks for a memory limit of at least 96M and recommends 128M. The 128M upload limits let you upload larger course files; raise or lower them to suit your content.
Moodle 5.3 needs MariaDB 11.4.0 or later, and Ubuntu 24.04's own package is MariaDB 10.11, so add MariaDB's repository first. MariaDB's setup script configures its newest release series by default; the option below pins it to 11.4, a long-term release that MariaDB's maintenance policy lists with community maintenance until May 29, 2029.
The database and its utf8mb4 character set are created the way Moodle's own Ubuntu guide creates them. Replace YOUR_STRONG_PASSWORD_HERE with a strong password (openssl rand -base64 32 generates one). When mariadb-secure-installation asks, remove the anonymous users, the remote root login and the test database; MariaDB's documentation notes that unix socket authentication is applied by default, so there is usually no need to create a root password.
Moodle's Git page says not to place the checkout itself in a web-accessible location and to point the web server at its public subdirectory, which is why the code lives in /var/www/moodle and Apache serves /var/www/moodle/public. Composer is optional in Moodle 5.3, except for new features such as the OAuth 2 server, and Moodle's install page says it will be required from Moodle 6.0; run the same composer command again every time you update the code, before you run the upgrade. The moodledata directory holds uploaded files, cache and session data and must not sit in a web-accessible folder; on a dedicated server Moodle's security recommendations give it to the web server user with 700 on directories.
Now create the Apache virtual host:
Replace your-domain.com with your real domain, and check that its DNS A record already points at the server. Since Moodle 5.1 the document root has to be Moodle's public directory, not the main Moodle folder. The Directory block is the one Moodle's router page gives for Apache, ending in FallbackResource /r.php, with AcceptPathInfo On from Moodle's Ubuntu guide. The FilesMatch block is the PHP-FPM handler from the same Ubuntu guide: it passes a PHP file to PHP-FPM only when that file exists, so every other address reaches Moodle's router. Moodle says a working router is not strictly required for a basic installation yet, and that it intends to make one mandatory in upcoming releases; step 6 switches it on.
Do not open the site in a browser yet. Moodle records the web address it is installed under, so switch on HTTPS first. Moodle's install page also recommends keeping the installer out of public reach until the installation is complete, so do not leave the site half-installed: finish steps 5 and 6 in one sitting.
Certbot requests a certificate from Let's Encrypt and installs it in Apache:
Certbot edits the Apache configuration to serve the certificate. Its instructions say the Certbot packages come with a cron job or systemd timer that renews certificates automatically before they expire. Those instructions install Certbot as a snap; the commands here use Ubuntu's certbot and python3-certbot-apache packages, as Moodle's Ubuntu guide does.
Basic hardening of the server:
These are the minimum. Hetzner's cloud firewall, which Hetzner does not charge for, can filter traffic before it reaches the server, and Hetzner's FAQ says newer Ubuntu images created with an SSH key already have password login for root switched off. For production, also consider automatic security updates for the operating system (the unattended-upgrades package), security headers in Apache and log monitoring.
Open https://your-domain.com in your browser. Moodle's installer starts; follow its pages:
/var/moodledatalocalhost, database: moodle, user: moodleuser, and the password you chose)Moodle's install page recommends its command-line installer instead, which asks the same questions in the terminal: sudo -u www-data /usr/bin/php /var/www/moodle/admin/cli/install.php.
Switch the router on. Moodle's sample configuration file marks the router as not configured, and the installer writes config.php without that setting, so Moodle's status report would say the router is not configured. Step 4 set the web server up for it. Once the installer has finished, add the setting above the last require_once line of config.php, as Moodle's Ubuntu guide does:
Lock the code down. Moodle's install page says it is vital that the files are not writeable by the web server user, and its security recommendations give root as owner with 755 on directories and 644 on files. Once the installer has written config.php and the router setting is in it:
From here on the web server can read the code but not change it. For a later update, give the code back to www-data first (the chown line in step 4), and run these three commands again when the update is done.
Set up cron. Moodle's background tasks, such as sending forum emails and running course backups, run from a cron script, and Moodle's cron page recommends running it every minute:
Final checks:
https://your-domain.com: Moodle loads over HTTPSsudo -u www-data /usr/bin/php /var/www/moodle/admin/cli/checks.php -v: it lists Moodle's status checks, and the Router configuration lines should read OKhttps://your-domain.com/fakefile.php, an address with no file behind it: a short page headed 404 Not Found that says "The requested resource could not be found" comes from Moodle's router, so the router answers; a bare "File not found." from PHP-FPM, or the web server's own error page, means it does notMoodle 5.3 is installed. What comes next decides whether the server is still healthy a year from now.
You have just completed six steps. These three questions check the decisions that cause trouble when they go wrong.
Why must the moodledata directory sit outside the web-accessible folder?10 pts
(select all that apply)
What happens if you do not set up Moodle's cron job?10 pts
(select all that apply)
Your Moodle is live and you need to raise PHP's upload limits. Where do you change them?10 pts
(select all that apply)
Installing Moodle is a one-time job. Keeping it secure and stable is ongoing work that does not end.
Moodle's release calendar has a major release every six months, in April and October, and a minor release every two months, and it lists the November 12, 2026 release of 5.3.1 as an unscheduled one. Each release brings fixes that you install yourself, and Moodle's security recommendations say to update Moodle regularly on each release. Our monthly list of Moodle security advisories shows what those releases fix.
These are the tasks to run on a schedule. They are not optional:
Weekly:
Monthly:
Every two to six months:
Yearly:
| Item | Do it yourself | Managed Moodle from Cubite |
|---|---|---|
| Server | Hetzner CPX32: EUR 30.49 a month in Helsinki, excluding VAT (November 17, 2026) | Managed Moodle hosting with your domain and TLS is included |
| Moodle license | None: Moodle is open source | None |
| Upgrades, security patches and backups | Your time | Included: version upgrades and same-day CVE patching, daily backups with a rehearsed restore, and each upgrade tested first on a staging copy of your site |
| Price | The server bill plus your time | From $690 a month (Standard, up to 500 concurrent learners) |
The question is less what the server costs than what your time is worth: put the hours you spend each month on updates, backups and monitoring next to the managed price. Cubite's managed Moodle costs $690 a month (Standard, up to 500 concurrent learners), $1,190 a month (Growth, up to 1,500) or from $2,200 a month (Scale, elastic, with cloud billed at cost), and SSO (SAML / OIDC) implementation is included in every tier. Other managed Moodle providers, Moodle Certified Partners among them, are in our Moodle hosting guide with their published prices.
There is no single answer. It depends on your team, your budget and how much risk you can carry.
| Your situation | Recommendation | Why |
|---|---|---|
| A sysadmin or DevOps team that has run Moodle upgrades before | Self-host | You keep the low server cost and have the people to maintain it |
| A small site, a tight budget and someone comfortable with Linux | Self-host | The task list above is manageable at a small scale |
| No technical staff, and the site matters to your business | Managed | Updates, backups and security patches need someone who does them on schedule |
| An uptime commitment, or many learners online at the same time | Managed | Ask each provider what it commits to; Cubite prices managed Moodle by peak concurrent learners |
| Strict rules about where the data sits | Self-host, or a managed provider that hosts where you need | Ask where the servers are before you sign |
Some providers will also manage a server that you rent yourself. If keeping the server in your own account matters to you, ask for that when you compare offers.
Versions, package names and prices were read on November 17, 2026 and change over time. Check each source before you build.
Would you rather not run the server?
Cubite runs managed Moodle from $690 a month for up to 500 concurrent learners. Bring your Moodle version, your plugins and your peak number of learners online, and we will walk through what a managed setup looks like.
Looking to learn more about moodle and Moodle, LMS? These related articles explore complementary topics, techniques, and strategies.
Compare Moodle hosting options (MoodleCloud, managed, self-hosted, and cloud) with real pricing, installation methods, and a decision framework.
An evidence-based Moodle LMS review drawing on 105 verified user ratings. Discover who gets the most value, what users love, and where Moodle falls short.
In 2026, Moodle disclosed a remote code execution flaw, a SQL injection bug, and a mobile-app token leak. Here is which version is exposed, how to check yours, and what to do when upgrading is not an option yet.
A monthly count from moodle.org's own registration chart, with the method and its limits.
Open edX is the free, open-source LMS built by Harvard and MIT. Here's what it does, who uses it, what it costs, and how it compares to Moodle in 2026.