> ## Documentation Index
> Fetch the complete documentation index at: https://genai.codewithsiva.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Multipage Apps

> Organize your Streamlit application using a pages directory

As your application grows, you can split it into multiple pages by creating a folder named `pages` in the same directory as your main entrypoint script.

### 1. Project Structure

Streamlit automatically detects any `.py` file inside the `pages/` folder and displays them in the sidebar:

```text theme={null}
my-app/
├── app.py          # Main landing page
└── pages/          # Must be named exactly "pages"
    ├── 1_📊_Dashboard.py
    └── 2_⚙_Settings.py
```

### 2. How it Works

* **Sidebar Ordering:** Streamlit sorts the files alphabetically. Prefix files with numbers (e.g., `1_`, `2_`) to enforce a custom order.
* **Display Names:** Streamlit cleans up the file names in the sidebar automatically (e.g., `1_📊_Dashboard.py` will display as `📊 Dashboard` by removing numbers, underscores, and file extensions).
* **Run the App:** Always run the main entry point:
  ```bash theme={null}
  uv run streamlit run app.py
  ```
