[GH-ISSUE #681] feat: option to disable users from deleting their chat history #27703

Closed
opened 2026-04-25 02:26:43 -05:00 by GiteaMirror · 8 comments
Owner

Originally created by @tbendien on GitHub (Feb 8, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/681

Originally assigned to: @tjbck on GitHub.

As the Ollama Web UI sysadmin I need to be able to download chat history from all users and also block users from deleting their chat history.

Describe the solution you'd like

  1. Enable the sysadmin to download use chat history on a per user basis for a given time range (up to the first day they used the OWUI app).
  2. Block end users from deleting chat history
  3. Ability to connect an S3 object storage bucket to OWUI so that chat history can be pushed into object storage vs being stored on the local host.

Describe alternatives you've considered
Bionic GPT has this capability by connecting to it's local postgres database which has access logs and chat history logs.
I'd like to do the same thing with OWUI.

Additional context
I need this capability for chat history security and compliance audit use cases.

Originally created by @tbendien on GitHub (Feb 8, 2024). Original GitHub issue: https://github.com/open-webui/open-webui/issues/681 Originally assigned to: @tjbck on GitHub. As the Ollama Web UI sysadmin I need to be able to download chat history from all users and also block users from deleting their chat history. **Describe the solution you'd like** 1. Enable the sysadmin to download use chat history on a per user basis for a given time range (up to the first day they used the OWUI app). 2. Block end users from deleting chat history 3. Ability to connect an S3 object storage bucket to OWUI so that chat history can be pushed into object storage vs being stored on the local host. **Describe alternatives you've considered** Bionic GPT has this capability by connecting to it's local postgres database which has access logs and chat history logs. I'd like to do the same thing with OWUI. **Additional context** I need this capability for chat history security and compliance audit use cases.
Author
Owner

@justinh-rahb commented on GitHub (Feb 8, 2024):

  1. This is partially addressed in #643, you can download all chats for all users if you're an admin.
  2. I agree that we probably need a toggle to disable user deletion of history if so desired by the admin. Shouldn't be too difficult to implement.
  3. This feels more "stretch goal" for now.
<!-- gh-comment-id:1934850996 --> @justinh-rahb commented on GitHub (Feb 8, 2024): 1. This is partially addressed in #643, you can download all chats for all users if you're an admin. 2. I agree that we probably need a toggle to disable user deletion of history if so desired by the admin. Shouldn't be too difficult to implement. 3. This feels more "stretch goal" for now.
Author
Owner

@tbendien commented on GitHub (Feb 8, 2024):

Thanks @justinh-rahb - I am looking to use OWUI in High Schools with minors, so we have Legal compliance requirements that need us to be able to run reports on user activity. We can't have the kids using the tool and then deleting harmful chat history. So that's why we need the feature to block deletion of chats by end users - safety..

<!-- gh-comment-id:1934856381 --> @tbendien commented on GitHub (Feb 8, 2024): Thanks @justinh-rahb - I am looking to use OWUI in High Schools with minors, so we have Legal compliance requirements that need us to be able to run reports on user activity. We can't have the kids using the tool and then deleting harmful chat history. So that's why we need the feature to block deletion of chats by end users - safety..
Author
Owner

@justinh-rahb commented on GitHub (Feb 8, 2024):

Thanks @justinh-rahb - I am looking to use OWUI in High Schools with minors, so we have Legal compliance requirements that need us to be able to run reports on user activity. We can't have the kids using the tool and then deleting harmful chat history. So that's why we need the feature to block deletion of chats by end users - safety..

Absolutely, I believe almost any scenario where an admin would want a way to download the history in bulk would likely also require that it not be removeable by users. At the moment, fine-grained access controls are still a planned feature as opposed to implemented, please see related issue #446

<!-- gh-comment-id:1934864410 --> @justinh-rahb commented on GitHub (Feb 8, 2024): > Thanks @justinh-rahb - I am looking to use OWUI in High Schools with minors, so we have Legal compliance requirements that need us to be able to run reports on user activity. We can't have the kids using the tool and then deleting harmful chat history. So that's why we need the feature to block deletion of chats by end users - safety.. Absolutely, I believe almost any scenario where an admin would want a way to download the history in bulk would likely also require that it not be removeable by users. At the moment, fine-grained access controls are still a *planned* feature as opposed to *implemented*, please see related issue #446
Author
Owner

@tjbck commented on GitHub (Feb 8, 2024):

I'll narrow down the scope of this feature request to just "blocking users with "user" role from deleting chat history". I don't plan on implementing the first and third requests in the near future, as they seem like very niche use cases. The third request could also be slightly modified to request for supporting external db like postgres. Feel free to create a separate issue/PR for the two.

<!-- gh-comment-id:1934962600 --> @tjbck commented on GitHub (Feb 8, 2024): I'll narrow down the scope of this feature request to just "blocking users with "user" role from deleting chat history". I don't plan on implementing the first and third requests in the near future, as they seem like very niche use cases. The third request could also be slightly modified to request for supporting external db like postgres. Feel free to create a separate issue/PR for the two.
Author
Owner

@explorigin commented on GitHub (Feb 9, 2024):

What if "delete" is just a flag in the database. Only show "not deleted" chats. So the admin options are: allow user delete, user delete = hide, disallow user delete.

<!-- gh-comment-id:1935285481 --> @explorigin commented on GitHub (Feb 9, 2024): What if "delete" is just a flag in the database. Only show "not deleted" chats. So the admin options are: allow user delete, user delete = hide, disallow user delete.
Author
Owner

@explorigin commented on GitHub (Feb 9, 2024):

Another future feature for this scenario would be an audit log. Delete could mean "remove from db" so long as it got dumped to the audit log.

<!-- gh-comment-id:1935286510 --> @explorigin commented on GitHub (Feb 9, 2024): Another future feature for this scenario would be an audit log. Delete could mean "remove from db" so long as it got dumped to the audit log.
Author
Owner

@tbendien commented on GitHub (Feb 12, 2024):

@tjbck @justinh-rahb is there any chance that you could implement the "blocking users with "user" role from deleting chat history" feature by end of this week? I am planning a demo next week and would be great if users are prevented from deleting chats by then. Thanks for the great project!!!

<!-- gh-comment-id:1938771123 --> @tbendien commented on GitHub (Feb 12, 2024): @tjbck @justinh-rahb is there any chance that you could implement the "blocking users with "user" role from deleting chat history" feature by end of this week? I am planning a demo next week and would be great if users are prevented from deleting chats by then. Thanks for the great project!!!
Author
Owner

@tjbck commented on GitHub (Feb 14, 2024):

@tbendien You can now toggle the setting from Admin Panel > Admin Settings > Users, let me know if you encounter any issues!

image

<!-- gh-comment-id:1943367192 --> @tjbck commented on GitHub (Feb 14, 2024): @tbendien You can now toggle the setting from Admin Panel > Admin Settings > Users, let me know if you encounter any issues! ![image](https://github.com/ollama-webui/ollama-webui/assets/25473318/0db808c5-433d-4313-bcc8-e020c661ecba)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#27703