PHP memory exhausted during large file uploads

resolved Nextcloud configuration Reported 2026-01-10 Verified 2026-03-01

Uploading files larger than 512MB causes PHP to exhaust memory, resulting in a white screen or 500 error.

Error Messages
Allowed memory size exhaustedFatal error: Out of memory
Versions: 28.029.0
OS: ubuntu-22.04ubuntu-24.04
Deployment: dockerbare-metal

Resolutions (1)

high confidence 35 verified

Increase PHP memory limit and upload limits:

# php.ini
memory_limit = 1G
upload_max_filesize = 16G
post_max_size = 16G

For Docker, add to your environment: PHP_MEMORY_LIMIT=1G

Verified by 35 users across versions Added 2026-01-15
Applies to: 28.0, 29.0 on docker, bare-metal
/ Search Esc Clear ? Sitemap
24 tools / 3 guides / 9 resolved issues