# Terminal > How to open a shell inside the service's container from the browser, and what gets recorded. The **Terminal** tab opens a shell inside the running container, right in the browser, with no SSH. Use it to investigate a problem, check files or run a quick command. ## Open the terminal 1. Open the service and go to the **Terminal** tab. 2. The terminal connects to the application container on its own. 3. To enter an extra process (e.g. `worker`), choose **Process: worker** in the selector at the top. **Application** goes back to the main container. 4. With replicas, also choose the server in the selector. ![Terminal tab of the api service connected to the application container](https://ployter.com/assets/docs/en/terminal-tab.webp) The shell runs as the image's user. The buttons at the top: - **New session**: opens another session in place of the current one. - **Connect** and **Reconnect**: reconnect after the session ends. To copy selected text, use `Ctrl+Shift+C`. > [!WARNING] > A file changed through the terminal disappears on the next deploy, unless it is on a volume. To change configuration permanently, use the **File Manager** tab or a volume. See [Service settings](https://ployter.com/en/docs/services/settings/#php-e-arquivos-de-configuracao) and [Volumes, files and SFTP](https://ployter.com/en/docs/services/volumes-and-files/). > [!TIP] > To run a command with its output kept in the history (migrations, scripts), use **Commands → Run command** instead. It runs in a new container and doesn't touch the one serving the site. See [Processes, scheduled jobs and commands](https://ployter.com/en/docs/services/processes-and-cron/#rodar-um-comando-avulso). ## When the session closes The session ends when: - You type `exit` or close the browser tab. - 30 minutes pass without typing. - The server goes offline or the agent disconnects. - Someone removes your terminal permission. If the image has no shell (minimal images, such as `distroless` ones), the terminal doesn't open. ## Recent sessions Below the terminal, **Recent sessions** lists who opened it, where (application or process, and the server), the start time, the duration and why it ended. The panel records who opened the terminal, when and where. What is typed isn't recorded. ## Requirements - The service must be on a server and have a running container. - The server agent must be up to date. If it isn't, the tab shows the minimum version. Update it in **Servers**. See [Servers](https://ployter.com/en/docs/servers/servers/). - The tab shows up for people with the **Open terminal** permission. See [Teams, members and roles](https://ployter.com/en/docs/team/members/). From the CLI, `ployter shell` opens the same terminal. See [CLI](https://ployter.com/en/docs/cli/cli/). The terminal for the whole server (outside the containers) is on the server screen. See [Servers](https://ployter.com/en/docs/servers/servers/).