Coding / Software Development
OpenWebUI integrates with Open Terminal — a sandboxed Linux environment with Python and common document libraries (pandas, openpyxl, python-docx, reportlab, fpdf2, weasyprint, matplotlib, xlsxwriter). Code runs in an isolated per-user environment; files created during execution appear in OpenWebUI's Files panel for download.
Requirements & current limitations
- Plain LLM models only. Code execution is driven by OpenWebUI's native
execute_codetool, so it works only with plain chat models that support function (tool) calling, and Native Function Calling must be enabled for the model (Admin → Settings → Models → the model's advanced params). Models without function-calling support cannot trigger the sandbox. - AI-Hub agents are not supported yet. Agent chats own their own generation and do not expose OpenWebUI's tool-calling handshake, so code execution does not engage for them. This is a planned follow-up.
There are two main ways to use code execution.
- Ask the model to write and run code. Mentioning a specific goal (e.g. "create a chart", "process this data") gives the model the context to generate and execute Python code that produces the result directly in the chat.
- Provide existing code and ask the model to run or improve it.
Coding with the LLM
Enter a prompt mentioning the "Pydiode environment" in order to generate code.

Using the "Run" button the code can be tested directly inside the chat.

Two execution paths
Model-driven execution — where the model decides to run code to compute an answer or produce a file — runs in the Open Terminal sandbox (server-side, with the document libraries above; generated files appear in the Files panel). The manual "Run" button on a code block uses OpenWebUI's built-in Pyodide engine (in-browser WebAssembly), which is lightweight but limited to its bundled packages and does not write files to the server.
After running the code snippet prints the result below the cell.

Executing existing code
Select "Code Interpreter".

Encase the code in back-ticks to mark it as code for execution.

When the code has run through the result is printed out.

Generated files
Files written during code execution (reports, spreadsheets, charts, etc.) automatically appear in OpenWebUI's Files panel, where users can download them. After creating a file the model will confirm the filename.
Isolation and limitations
Shared-container, per-user isolation
Open Terminal runs in a single shared container with OPEN_TERMINAL_MULTI_USER enabled: each user gets a separate Linux account and home directory (/home/<user>), and standard filesystem permissions keep one user's files private from another. This is per-user isolation inside one container, not a container-per-user model — all users share the same kernel, CPU, memory, /tmp, and process list. It suits small, trusted groups; it is not a hard multi-tenant security boundary. Treat the sandbox as a convenience for collaborators, not as a barrier between mutually untrusted parties.
Stored files grow over time
Each user's generated files persist on the host (the open-terminal /home volume) and are not cleaned up automatically — there is currently no retention or quota policy. Disk usage grows with use; operators should monitor the volume and prune old per-user data manually until an automated cleanup/TTL is added.
