Appwrite is moving from PHP to Rust: what it means for Moodle

Appwrite is moving its PHP server to Rust one service at a time. What it announced, the benchmarks, how it keeps both running, and what Moodle teams can learn.

Drawing of two workers swapping one brick at a time in a grey wall for blue bricks, while the wall keeps standing.

Short answer: on 22 November 2026, Appwrite said it is moving its server from PHP to Rust.1 Appwrite is an open-source backend platform: auth, databases, storage, functions. It is not doing a big-bang rewrite. Rust goes in two ways. First, Rust libraries run inside the PHP server as extensions. Then whole services move to Rust one by one, behind the same proxy, on the same databases. Nothing changes for people who call its API. For Moodle this is not a sign that core is next. It is a worked example of how to move a large PHP codebase without stopping it, and of what AI coding agents do to the cost of that kind of work.

What did Appwrite announce?

The post is by Eldad Fux, Appwrite’s founder and CEO. The key points:

  • Size of the job. Hundreds of thousands of lines, 29 API services and more than 700 endpoints.1
  • Why now. AI coding agents “changed the math”, so a migration that once took years is “now measured in weeks”. Speed and lower running costs come next, and Fux says the move could allow lower Cloud prices.1
  • Why not before. The post says PHP did not let them down. In 2022 a community member opened an issue asking for a full Rust rewrite. Appwrite closed it in August 2023 and said it was happy with its PHP stack. It reopened the issue in October 2026 and commented “OK, we’re going for it” on 23 November.2
  • First services. Users, Teams and Storage.1
  • For developers using Appwrite. Same requests, same responses, same SDKs, same data. The PHP SDK and the PHP Functions runtime stay supported.1

There was Rust work before this. Appwrite released an official Rust server SDK in April 2026 and a Rust runtime for Functions in May 2026.34

How are they moving without a rewrite?

There are two tracks, and they run together.1

Rust inside PHP. The PHP server moves to swoole-rs, a Rust base that keeps the Swoole programming model. Each of Appwrite’s Utopia PHP libraries gets a Rust crate with the same API. The crate loads into PHP as an extension, so PHP code calls it as before. A compatibility tester recorded 43,075 cases from the PHP libraries and replays them against the Rust versions.

Rust beside PHP. Once a service is ready, the proxy sends that service’s paths to a Rust process. Both runtimes share the same database (MongoDB, PostgreSQL or MySQL), Redis, queues and caches, so switching a service takes no data migration. Each service starts on a small share of traffic. It is compared with the PHP baseline, then given more. A parity tool compares responses, database changes and cache effects on both sides.

To do this they moved 48 Utopia PHP libraries into the main Appwrite repository, beside their Rust versions. Each library is still published to its own repository.1

How much faster is it?

These are Appwrite’s own numbers. They were measured on one Apple M4 Max with k6, with both runtimes on the same database, Redis and cache.1

Users APIPHPRustChange
Requests per second (50 virtual users)1,0452,7582.6x more
CPU per request (200 req/s)4.34 ms0.76 ms5.7x less
Average memory (200 req/s)1,957 MiB58 MiB33x less
Median latency (200 req/s)6.3 ms1.5 ms4.2x lower

Storage also improved, but by less: 2.1x the throughput, 8x less CPU per request and 2.9x less peak memory. Across 230 library benchmarks the average gain was about 3.5x.1

Treat this as a first look. One laptop is not a production cluster. The post does not say how long each test ran or how many times. It also gives 48, 49 and 50 as the library count in different places. The direction is believable. The exact multiples are marketing until someone else reproduces them.

Will Moodle move to Rust next?

No. We wrote about this two weeks ago in Will Moodle ever use Rust?, and Appwrite’s move does not change the answer. The reasons are specific to Moodle:

  • Plugins. Appwrite’s users talk to it over HTTP, so they do not care what language the server is in. Moodle’s plugins are PHP code that calls Moodle’s PHP APIs directly, and there are thousands of them, plus the private plugins every institution keeps. A Rust Moodle breaks all of them.
  • Hosting. Moodle 5.3 needs PHP and a database, nothing else. It runs on any host that runs PHP. Appwrite already ships as Docker containers, so one more binary in the image changes little for its users.
  • Who runs it. Appwrite is one company that controls its whole deployment. Moodle runs on more than 145,000 registered sites, hosted by thousands of different teams.

What can Moodle teams take from it?

The way Appwrite is doing it carries over even though the language choice does not.

  1. Prove parity before you switch. Appwrite records real behaviour and replays it against the new code. We did the same, on a smaller scale, when we ported the devlms.com backend from TypeScript to a Rust binary. Golden tests made from the TypeScript side check that prices, prompts and rules stay identical in Rust. Without those tests the port would have been a guess.
  2. Move one piece at a time behind a stable interface. For Moodle that interface is the plugin API, web services and the database. You can replace a heavy part of your own platform (a report builder, a file converter, a sync job) with a separate service that Moodle calls, and keep the PHP side small. That is how Rust or Go reaches a Moodle site without touching core.
  3. Put a hot path in an extension. ext-php-rs builds PHP extensions in Rust today. Moodle cannot require one, but your own servers can, for work like image or document processing.
  4. The cost of this work has fallen. Appwrite’s main reason is that AI agents made a large migration cheap. The same is true one level down. Upgrading an old Moodle plugin to 5.x, adding the tests it never had, or splitting a slow cron task into a service used to be work nobody had budget for. It is now days, not months, as long as the tests prove the new code behaves like the old.

If you have an old Moodle plugin or integration that needs this kind of move, tell us what it does and we will scope it.

Sources

  1. Appwrite blog, Appwrite is moving from PHP to Rust, Eldad Fux, 22 November 2026. Read 25 November 2026. ↑ ↑ ↑ ↑ ↑ ↑ ↑ ↑ ↑

  2. GitHub, appwrite/appwrite issue #4423: Rewrite entire Appwrite PHP codebase in Rust, opened 11 October 2022, closed 22 August 2023, reopened 13 October 2026. ↑

  3. Appwrite blog, Introducing the Appwrite Rust SDK. ↑

  4. Appwrite changelog, Rust runtime for Appwrite Functions, 4 May 2026. ↑

Need a Moodle plugin built or rescued?

Tell the scoping assistant what you need. You get a fixed price and a timeline in a few minutes, and an engineer reviews it within one business day.

Get a fixed quote