[GH-ISSUE #17958] issue: Tab characters in text pasted into chat textbox are removed after submission #33977

Closed
opened 2026-04-25 07:51:58 -05:00 by GiteaMirror · 6 comments
Owner

Originally created by @rotemdan on GitHub (Oct 1, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/17958

Check Existing Issues

  • I have searched for any existing and/or related issues.
  • I have searched for any existing and/or related discussions.
  • I am using the latest version of Open WebUI.

Installation Method

Docker

Open WebUI Version

v0.6.32

Ollama Version (if applicable)

No response

Operating System

Windows 11 24H2

Browser (if applicable)

Brave 1.82.172 (Official Build) (64-bit) Chromium: 140.0.7339.207

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have provided every relevant configuration, setting, and environment variable used in my setup.
  • I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
  • I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
  • Start with the initial platform/version/OS and dependencies used,
  • Specify exact install/launch/configure commands,
  • List URLs visited, user input (incl. example values/emails/passwords if needed),
  • Describe all options and toggles enabled or changed,
  • Include any files or environmental changes,
  • Identify the expected and actual result at each stage,
  • Ensure any reasonably skilled user can follow and hit the same issue.

Expected Behavior

Tab characters preserved.

Actual Behavior

Seems to remove the tab characters. Issue likely started on latest release.

Steps to Reproduce

Paste some code with tab characters:
Image

Result:
Image

Logs & Screenshots

Included.

Additional Information

Also occurs in Firefox.
Rich text and predictive text modes disabled.

Originally created by @rotemdan on GitHub (Oct 1, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/17958 ### Check Existing Issues - [x] I have searched for any existing and/or related issues. - [x] I have searched for any existing and/or related discussions. - [x] I am using the latest version of Open WebUI. ### Installation Method Docker ### Open WebUI Version v0.6.32 ### Ollama Version (if applicable) _No response_ ### Operating System Windows 11 24H2 ### Browser (if applicable) Brave 1.82.172 (Official Build) (64-bit) Chromium: 140.0.7339.207 ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.** - [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc). - [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps: - Start with the initial platform/version/OS and dependencies used, - Specify exact install/launch/configure commands, - List URLs visited, user input (incl. example values/emails/passwords if needed), - Describe all options and toggles enabled or changed, - Include any files or environmental changes, - Identify the expected and actual result at each stage, - Ensure any reasonably skilled user can follow and hit the same issue. ### Expected Behavior Tab characters preserved. ### Actual Behavior Seems to remove the tab characters. Issue likely started on latest release. ### Steps to Reproduce Paste some code with tab characters: <img width="1270" height="729" alt="Image" src="https://github.com/user-attachments/assets/e6500a5d-7eb0-4f65-8370-30e4e83563a1" /> Result: <img width="1301" height="727" alt="Image" src="https://github.com/user-attachments/assets/41b5c9af-481e-450d-b616-bf8289ff1988" /> ### Logs & Screenshots Included. ### Additional Information Also occurs in Firefox. Rich text and predictive text modes disabled.
GiteaMirror added the bug label 2026-04-25 07:51:58 -05:00
Author
Owner

@rgaricano commented on GitHub (Oct 1, 2025):

This is caused by the paste handling logic in the RichTextInput component, which is used for the chat input field.
When richText mode is disabled (plain text mode), the component explicitly strips HTML formatting and processes the pasted content line by line, which can affect tab characters.

Try enabling RichText in userSettings/Interface/Input Section

<!-- gh-comment-id:3355212188 --> @rgaricano commented on GitHub (Oct 1, 2025): This is caused by the paste handling logic in the RichTextInput component, which is used for the chat input field. When richText mode is disabled (plain text mode), the component explicitly strips HTML formatting and processes the pasted content line by line, which can affect tab characters. Try enabling RichText in userSettings/Interface/Input Section
Author
Owner

@rotemdan commented on GitHub (Oct 1, 2025):

This seems to be likely a new issue in the latest release(s). Haven't seen it recently.

Rich Text mode has various issues for general text editing of complex markdown and other types of prompts. I don't think enabling it is would be an overall effective strategy. Not all users prefer it.

<!-- gh-comment-id:3355226167 --> @rotemdan commented on GitHub (Oct 1, 2025): This seems to be likely a new issue in the latest release(s). Haven't seen it recently. Rich Text mode has various issues for general text editing of complex markdown and other types of prompts. I don't think enabling it is would be an overall effective strategy. Not all users prefer it.
Author
Owner

@tjbck commented on GitHub (Oct 1, 2025):

Should be addressed in dev, testing wanted here!

<!-- gh-comment-id:3357430858 --> @tjbck commented on GitHub (Oct 1, 2025): Should be addressed in dev, testing wanted here!
Author
Owner

@silentoplayz commented on GitHub (Oct 1, 2025):

Should be addressed in dev, testing wanted here!

I can confirm this issue is fixed for code blocks on the dev branch. I have also tested out OP's issue before the fix and could confirm the issue existed before the fix.

Image Image

But it is not solved for plain text (if that's determined to be an issue)

Image Image
<!-- gh-comment-id:3357874808 --> @silentoplayz commented on GitHub (Oct 1, 2025): > Should be addressed in dev, testing wanted here! I can confirm this issue is fixed for code blocks on the `dev` branch. I have also tested out OP's issue before the fix and could confirm the issue existed before the fix. <img width="1035" height="387" alt="Image" src="https://github.com/user-attachments/assets/c91d791c-5efe-48f8-bd9f-a1aff171cb0b" /> <img width="1051" height="283" alt="Image" src="https://github.com/user-attachments/assets/cb347939-e989-4990-abd1-cda021887b14" /> But it *is not* solved for plain text (if that's determined to be an issue) <img width="1029" height="264" alt="Image" src="https://github.com/user-attachments/assets/6b4d7388-0893-4dcd-8ad4-d748e363c675" /> <img width="359" height="191" alt="Image" src="https://github.com/user-attachments/assets/c0a7f127-e91c-420e-affd-9b09d61eeb6f" />
Author
Owner

@tjbck commented on GitHub (Oct 1, 2025):

@silentoplayz the plain text one is purely cosmetic from the UI rendering side so this is working as intended, thanks for confirming!

<!-- gh-comment-id:3358036112 --> @tjbck commented on GitHub (Oct 1, 2025): @silentoplayz the plain text one is purely cosmetic from the UI rendering side so this is working as intended, thanks for confirming!
Author
Owner

@silentoplayz commented on GitHub (Oct 3, 2025):

Closing this issue.

<!-- gh-comment-id:3367508463 --> @silentoplayz commented on GitHub (Oct 3, 2025): Closing this issue.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#33977