Skip to main content
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:

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: