# Terminal and Files

> Part of the NocoDB documentation (Factory). Index of all pages: https://nocodb.com/llms.txt. Any docs page is available as Markdown by adding `.md` to its URL.

URL: https://nocodb.com/docs/factory/terminal-and-files
Last updated: 2026-10-21

Run your own commands on the machine of a Noco Factory session in the Terminal tab, and read, compare and edit the repository's files in the Files tab.

<AskNocoAI where="in a factory session">
  <Prompt>
    Run [the test suite] and show me what fails
  </Prompt>

  <Prompt>
    Show me the last [50] lines of [the dev server log]
  </Prompt>

  <Prompt>
    Open [src/config.ts] and explain what it sets
  </Prompt>
</AskNocoAI>

The **Terminal** and **Files** tabs of a Noco Factory session give you direct access to the session's machine. Use **Terminal** to run your own commands next to [NocoAI](/docs/product/noco-ai). Use **Files** to read a file, compare it with the start of the session, or make a small edit yourself.

## Terminal

The **Terminal** tab opens real shells on the machine of the session, in the repository folder. Use it to run a command, check a log, or look at what NocoAI did.

* To open another shell, click **New terminal**. A session can have up to 5 terminals at the same time.
* Each shell shows as a tab: **Terminal 1**, **Terminal 2** and so on. To close a shell, click the close button on its tab.
* Click a file path in the output to open the file in the **Files** tab.
* Click a local address, for example `http://localhost:3000`, to open it in [Preview](/docs/factory/live-screen-and-preview#preview).

Only the person who started the session sees the **Terminal** tab.

<Callout type="note">
  Screenshot pending: the Terminal tab with two shell tabs and the New terminal button.
</Callout>

### Terminal messages

| Message                                                                    | What to do                                        |
| -------------------------------------------------------------------------- | ------------------------------------------------- |
| "Connecting…"                                                              | Wait. The shell connects to the machine.          |
| "Shell exited with code \[code]. Press Enter to start a new one."          | Press Enter to start a new shell.                 |
| "Disconnected from the machine. Press any key to reconnect."               | Press any key. If the machine slept, it wakes up. |
| "This session already has 5 terminals running. Close one to open another." | Close a shell, then click **New terminal** again. |

## Files

The **Files** tab shows the file tree of the repository on the machine. Click a file to read it. For a file that the session changed, the tab shows the diff first. Click **File** to read the whole file, and **Diff** to see the changes again.

To change a file yourself:

1. Open the file in the **Files** tab.
2. Click **Edit**.
3. Make the change.
4. Click **Save**.

If you leave a file with unsaved changes, NocoDB asks **Discard changes?**. If NocoAI changed the same file while you edited it, the save stops: "It changed on the machine meanwhile. Reload and try again."

Only the person who started the session can edit files. Other members can read them.

<img alt="The Files tab with README.md open" src={__img0} placeholder="blur" />

## Good to know

* For a large file, the **Files** tab shows only the beginning: "Large file (\[size]). Only the beginning is shown." Click **Open anyway** to load the whole file before you edit it.
* Binary files, for example images, show "Binary file. There is nothing to show."
* To see all changes of the session in one place, use the [Changes](/docs/factory/review-changes) tab.

## Related

* [Review changes](/docs/factory/review-changes)
* [Live screen and preview](/docs/factory/live-screen-and-preview)
* [Sessions](/docs/factory/sessions)
* [Machines](/docs/factory/machines)

---

## Related pages

- [Noco Factory](https://nocodb.com/docs/factory.md): Noco Factory is the AI coding agent of NocoDB. NocoAI takes a task to its own cloud machine and branch, and returns a GitHub pull request for you to review.
- [Noco Factory and Other Coding Agents](https://nocodb.com/docs/factory/coding-agents.md): Compare Noco Factory with cloud AI coding agents such as Devin, OpenAI Codex and the GitHub Copilot coding agent, and see when Noco Factory is the right fit.
- [Connect GitHub](https://nocodb.com/docs/factory/connect-github.md): Connect GitHub to Noco Factory with the NocoDB GitHub App, choose the repositories that NocoAI can reach, and see what access it gets in a session.
- [Create a Factory](https://nocodb.com/docs/factory/create-factory.md): Create a NocoDB factory from a GitHub repository: pick the repository on the workspace home screen, and NocoAI sets up the project in the first session.
- [Sessions](https://nocodb.com/docs/factory/sessions.md): Start a Noco Factory session to give NocoAI a coding task on a branch, a pull request or an issue, and manage sessions: rename, archive, resume and delete.
- [Live Screen and Preview](https://nocodb.com/docs/factory/live-screen-and-preview.md): Watch NocoAI work on its machine's desktop in Noco Factory with Live screen, and try the app it runs in Preview, from the side panel of a session.
- [Review Changes](https://nocodb.com/docs/factory/review-changes.md): Review the code changes of a Noco Factory session in the Changes tab, comment on lines of the diff, and send the comments back to NocoAI to fix.
- [Branches and Pull Requests](https://nocodb.com/docs/factory/branches-and-pull-requests.md): How each Noco Factory session works on its own git branch, and how NocoAI commits, pushes and opens a GitHub pull request for you to review and merge.
