# Terminal

## IDE Terminal

The IDE provides two types of terminals: **Preview Terminal** and **Terminal**.

***

### Preview Terminal

The **Preview Terminal** is a specialized terminal that runs automatically when the IDE starts. It executes the **`monaca:preview`** script, which is defined in the project to create a development server for previewing content.

<figure><img src="/files/nbUpxosvqkL6sXPNMt97" alt="" width="563"><figcaption></figcaption></figure>

#### Identifying the Preview Terminal

* The **Preview Terminal** can be distinguished from a standard terminal by its title: **monaca:preview**.
* It is recommended to keep the **Preview Terminal** running, as it is essential for providing content to the **previewer**.

#### Restarting the Preview Terminal

If the **Preview Terminal** is accidentally closed or fails to start, you can reopen it by following these steps:

1. Open the **Command Palette**.
2. Search for **"Monaca: Open Previewer Terminal"** and select it.

<figure><img src="/files/54ku6oKmVegKnP4QzVxh" alt="" width="563"><figcaption></figcaption></figure>

***

### Terminal

The standard **Terminal** allows you to execute commands and manage your project environment.

#### Creating a New Terminal

To create a new terminal:

1. Click the **"+"** icon in the terminal panel.

<figure><img src="/files/J3zcAIjfSMZbvHFO66O0" alt="" width="563"><figcaption></figcaption></figure>

2. A new **Bash terminal** will be created alongside the existing **Preview Terminal**.

<figure><img src="/files/UK8Bheak2FCLAo84Wnwa" alt="" width="563"><figcaption></figcaption></figure>

#### Initial Setup

* When a new terminal is opened, it automatically executes **`.monacarc`** to set up the environment, such as configuring the Node.js version.
* You can run standard **Bash commands** in this terminal.\
  \&#xNAN;*(Example: Running the `ls` command to list project files and directories.)*

#### Deleting a Terminal

To close a terminal:

1. Hover over the terminal title (e.g., **Bash**).
2. Click the **delete (trash bin)** icon.

***

### Notes

* Free-plan users may have certain limitations when using the terminal.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://en.docs.monaca.io/products_guide/new-monaca-cloud-ide/terminal.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
