1

Install the Preswald SDK

pip install preswald

or 

uv pip install preswald
Need the latest version? Upgrade anytime:
pip install --upgrade preswald

or 

uv pip install --upgrade preswald
2

Set Up Your First Project

Run these commands to bootstrap your first Preswald app:

preswald init my_project
cd my_project

This will create a scaffolded project with the following:

  • hello.py: A starter Python script to get you going.
  • preswald.toml: Your app’s configuration settings.
  • secrets.toml: A secure place for sensitive data.
  • .gitignore: Pre-configured to exclude sensitive files from version control.
3

Write Your First App

Open hello.py and edit it with the following content:

from preswald import text

text("# Welcome to Preswald")

Run It Locally

Launch your app locally with this command:

preswald run

Open your browser and navigate to http://localhost:8501. Your app will be live, ready for you to explore and iterate on.

4

Deploy Your App

When you’re ready to deploy your app, run this:

preswald deploy --target structured
5

You will be prompted to pass in your GitHub username and Preswald API key. Get the preswald API key from our cloud console. Click on Organization name > Manage > API Keys.