Application hosting

Hosting Moodle

Moodle runs online courses, assessments and learning resources. Active students, course files and scheduled processing affect server demand, with release-specific PHP and database requirements to check first.

Requirements last checked against the project's documentation.

A sensible first server for Moodle is 2 vCPU, 2 GB RAM and 20 GB of storage. The cheapest listed plan that fits is OVHcloud VPS-1 (US) at $4.54/month.

Min memory
0.5 GiB
Min storage
5 GiB
  • LicenseGPL-3.0

Understand the setup

Find the software and services needed to run the application.

See requirements

Budget your resources

Plan memory, storage and CPU for the way you will use it.

Open resource planner

Build your shortlist

Compare plans for the starting size, then review the provider and billing terms.

See plans

Must have

Installation requirements

  • 64-bit PHP 8.3 or 8.4, with Sodium enabled
  • A database supported by Moodle 5.2
  • PHP max_input_vars set to at least 5000

Recommended

Planning guidance

  • Memory: 1 GB or more recommended (512 MB minimum); 8 GB or more on a large production server.
  • Processor: 2 GHz dual core or better recommended.
  • Disk: about 5 GB is a realistic minimum, plus space for course content.

Minimum installation resources

Moodle lists 512 MB RAM as a minimum and 1 GB or more as recommended, a dual-core 2 GHz processor, and about 5 GB of disk as a realistic minimum plus space for course content. Large production servers are likely to need 8 GB or more.

Where to start

A sensible first server for Moodle

vCPU
2
RAM
2 GB
Disk
20 GB

Built on Moodle's own figures (1 GB or more recommended, dual-core, 5 GB realistic minimum disk) with room for the database on the same server and course files. Busy sites and large installations need more; Moodle points to 8 GB or more on large production servers.

Moodle installation requirements · Size it for your workload

Our shortlist

Cheapest plans that meet this size

  1. OVHcloud Lowest price

    OVHcloud VPS-1 (US)

    • 2 vCPU
    • 4 GB RAM
    • 40 GB NVMe SSD
    $4.54/mo list price
  2. VPSDime

    Linux4GB

    • 2 vCPU
    • 4 GB RAM
    • 20 GB SSD
    $5.00/mo list price
  3. KnownHost

    Unmanaged VPS Entry Plus

    • 2 vCPU
    • 2 GB RAM
    • 50 GB NVMe
    $10.00/mo list price
  4. RamNode

    Standard VPS 2 GB

    • 2 vCPU
    • 2 GB RAM
    • 80 GB SSD
    $10.00/mo list price
  5. Amazon Web Services

    Amazon Lightsail · 2 vCPU / 2 GB

    • 2 vCPU
    • 2 GB RAM
    • 60 GB SSD
    $10.00/mo list price
  6. Hivelocity

    Hivelocity pro.sm.amd

    • 2 vCPU
    • 4 GB RAM
    • 40 GB NVMe SSD
    $10.00/mo list price
  7. Namecheap

    Pulsar

    • 2 vCPU
    • 2 GB RAM
    • 40 GB SSD RAID 10
    $11.88/mo list price
  8. Google Cloud

    Compute Engine e2-small · 2 vCPU / 2 GB

    • 2 vCPU
    • 2 GB RAM
    $12.23/mo hourly × 730

One cheapest plan per provider, based on each provider's standard list price. Check the plan page for introductory and renewal pricing before you buy.

Deploy with

Supported paths

  • Self-managed PHP application behind Apache or Nginx
  • Moodle-hosted or certified-partner services, with separate operating and support models

The host must provide

Runtime

PHP
8.3 minimum for Moodle 5.2; 8.4 is also supported
PHP architecture
64-bit PHP only
PHP extension
Sodium is required; max_input_vars must be 5000 or higher
Database
PostgreSQL 16+, MySQL 8.4+, MariaDB 10.11+, Aurora MySQL 8.0+, or SQL Server 2019+
Web server
Apache or Nginx; configure the Moodle 5.2 public directory as the web root

Storage

Persistent data

Moodle stores course uploads and other files in its moodledata directory. Keep this directory outside the public web root, use persistent storage, and allow space for course content, temporary files and retained backups.

Step by step

Moodle 5.2 deployment outline

  1. Select the release and supported stack

    Check the Moodle 5.2 release page, install 64-bit PHP 8.3 or 8.4 with Sodium, and select one of the documented database versions.

    Official instructions
  2. Set the public document root and private data path

    For Moodle 5.1 and later, configure the web server to serve the public directory. Store moodledata outside the public web root and make it writable only by the application service.

    Official instructions
  3. Schedule Moodle cron

    Configure the command-line cron script to run regularly; Moodle recommends every minute and warns that scheduled tasks are required for normal operation.

    Official instructions
  4. Check the environment and recovery path

    Run Moodle’s environment checks for the selected release, configure HTTPS, and test restoring the database and moodledata together before real courses depend on the site.

    Official instructions

Security

Before you go public

  • Keep moodledata outside the public document root.
  • Use a dedicated database account and restrict database permissions to the Moodle database.
  • Patch the operating system, PHP, database, Moodle core, and plugins; use HTTPS and test backups.

Cost

Beyond the server price

  • Budget for compute, database storage, course files, backups, email delivery, and any separate managed support.
  • Capacity and cost depend on concurrent learners, course activities, file retention, and reporting jobs; no fixed server size is implied.

Want the full monthly bill? Use the hosting cost calculator. Add storage, backups and other costs to your estimate.