mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-06 10:58:17 -05:00
[GH-ISSUE #19810] feat: Apply document upload limits of chats also to folders #57671
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Ithanil on GitHub (Dec 8, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/19810
Check Existing Issues
Verify Feature Scope
Problem Description
Currently, the existing Max Upload Count / Size limits only apply when uploading files directly to chats. The same limits do not apply when creating folders and uploading files there to be used by chats.
Because uploading files to folders basically serves as a default setup for contained chats, applying the same chat limits to folders would be logical. Also, if an admin chose to limit uploads for chats he likely wants to limit it for folders as well.
Desired Solution you'd like
Simply apply the Max Upload Size / Count settings to folders, just as they are applied to chats. I.e. creating the folder fails with an error message (ideally without closing the window and forcing the user to re-iterate, but that's optional).
Alternatives Considered
No response
Additional Context
No response
@owui-terminator[bot] commented on GitHub (Dec 8, 2025):
🔍 Similar Issues Found
I found some existing issues that might be related to this one. Please check if any of these are duplicates or contain helpful solutions:
#533 Uploading and Embedding Folders
by mafrasiabi • Jan 19, 2024
#14596 feat: Allow file upload when editing a previous chat message
by riendril • Jun 02, 2025
#13275 feat: Ability to remove attached files in chat
by mjp0 • Apr 28, 2025
💡 Tips:
This comment was generated automatically by a bot. Please react with a 👍 if this comment was helpful, or a 👎 if it was not.
@Ithanil commented on GitHub (Dec 12, 2025):
@Classic298 Any insights on whether this is going to be changed (as proposed)? If the given proposal is acceptable, I can also work on a PR myself.
@Classic298 commented on GitHub (Dec 12, 2025):
@Ithanil sorry this is beyond what i feel comfortable deciding.
me personally? i think it should be implemented, yes.
but it's beyond what i think is in my scope to decide so we'll have to ask @tjbck here.
@ShirasawaSama commented on GitHub (Dec 30, 2025):
Caused by #15898
9f5c905592@ShirasawaSama commented on GitHub (Dec 30, 2025):
We encountered this issue today as well.
One of our users uploaded a complete Node.js project folder to the knowledge base, which included the
node_modulesdirectory containing hundreds of thousands of files. It nearly maxed out our server's network bandwidth. 😂We then immediately banned this user and contacted them directly by phone to inquire about the reason: they wanted to use the knowledge base to analyze code. We informed them that we currently do not support this functionality and suggested that uploading a ZIP file might be a better alternative.
@Classic298 commented on GitHub (Dec 30, 2025):
We should use this issue to also discuss this for knowledge base limits (num of files, file size, and knowledge base size) cc @ShirasawaSama
@Classic298 commented on GitHub (Dec 30, 2025):
and we should come up with a proper solution, like, logically speaking
if we introduce limits for folders and knowledgebases, should they be the same as for individual chat uploads like they already exist?
what if we reuse them?
what if you configure a file amount limit of 10 and a user uploads 10 files to a folder and then starts a chat inside the folder and uploads an additional 10 files to that chat? should that be allowed?
what is the consensus here do you guys think?
CC @Ithanil
@ShirasawaSama commented on GitHub (Dec 31, 2025):
I strongly recommend separating the file upload limit in regular chats from the file folder upload limit in the knowledge base.
In regular chats, RAG can be bypassed, but it is enforced in the knowledge base.
@Ithanil commented on GitHub (Dec 31, 2025):
Agree, but I want to make clear that I didn't originally talk about knowledge bases in this issue. I mean the chat folders, for which IMO applying the same limits as for chats would make sense.
@Ithanil commented on GitHub (Dec 31, 2025):
So, given that we keep a basic file size/count kind of limitation, my idea would be the following:
Use a global per-file size limit, because I think the main purpose here is to "protect" the document extraction engine (which is configured globally) as well as to play well with configured max body sizes. Also, it then serves as an anchor to determine the maximum amount of data stored in a given number of files.
Use the same file count limit for folders and chats
If that limit is already reached due to the folder setup, IMO it should not be possible to add more files in a chat in that folder.
That would be my suggestion for a quick "fix" with the current system. Ultimately however, it would be desirable to have a quota for the total amount of data currently stored in the system by a single user. And I think that would concern both the storage consumed by the files as well as the number of chunks in the vector store.
@tjbck commented on GitHub (Jan 1, 2026):
FOLDER_MAX_FILE_COUNTintroduced in dev!@ramidahbash commented on GitHub (Jan 20, 2026):
What does the new FOLDER_MAX_FILE_COUNT specify exactly? is it the number of files that can be in a single knowledge? is it the max amount of files a user can upload to a knowledge at a time? is it both? or is it something else completely?
Thanks for the response
@Classic298 commented on GitHub (Jan 20, 2026):
@ramidahbash PLEASE read the docs
https://docs.openwebui.com/getting-started/env-configuration#folder_max_file_count
https://docs.openwebui.com/troubleshooting/rag/#6-upload-limits-and-restrictions-
"This limit applies to the number of files directly associated with a folder."