Matrix Server Max File Upload Size

Howdy! I made a Matrix server for some friends and I and was really trying to stretch the utility of the matrix platform. I wanted to share some bigger files but the upload seems to be stuck at 50MB. I changed the field in homeserver.yaml from 50M to 2048M and the reloaded the service with no errors. Then when I went to upload a file that was 1.3G it told me that the upload limit was still 50MB. I was trying to eliminate the need for dropbox or the like when collaborating on projects. Unfortunately there just does not seem to be much info out there on this issue. Any help would be great!

TL;DR: How do I increase the size limit for uploading files on my matrix server?

Are you using nginx as your reverse proxy? If so you might need to increase the upload size there too.

Edit the config:

/etc/nginx/nginx.conf

Change value:

client_max_body_size 2048M;

1 Like

If you set that field to 0 it makes uploads unlimited.

1 Like

And if the server is cloud hosted make sure you setup billing or usage alerts to avoid any surprise data transfer overages

2 Likes

I will check that out in the morning, thanks!

That is good to know

I updated the nginx.conf and reloaded the service, but to no avail. Thanks for the help and if there is anything else you can think of I am always open to ideas but I am at nuke and pave lol (not that my tool box for this issue was super deep)

Update:
Not sure what happened. After adding the line to the nginx config I reloaded the service and it didn’t work at all. I put everything back the way it was and reloaded again and now it is trying to upload bigger files and failing differently around 700MB. Will update again if I get something over a gig to go!