Optimize the speed of Nextcloud over the Raspberry Pi
12 min readMar 15, 2022
So, you put everything together, but you aren’t that satisfied with the Nextcloud performance of your Nextcloud installation.
— Updated for 2024 —
While this is tested on Raspberry Pi OS, you can optimize other device that is running Nextcloud on top of Debian, Ubuntu or similar with this guide.
Shortlist of what you need to do to increase performance
Consider that you got a Raspberry Pi 3, 4 or the new 5, you should be able to squeeze a bit more performance from your cloud by:
- Disable unnecessary apps;
- Switch to PHP-FPM;
- Increase PHP memory limit;
- Enable HTTP/2;
- Enabling OPCache JIT;
- Enable APCu for local caching;
- Modify temporary upload directory;
- Configure MariaDB database parameters;
- Install and activate Redis cache;
- Downsize and reduce the quality of image thumbnails and previews;
- Using Imaginary to create image previews;
- Enable zRAM for low memory devices;
Disabling unnecessary Nextcloud apps
By default, Nextcloud comes with a list of apps enabled, so these consume memory and make the pages load slower.