https://github.com/whitphx/stlite
In-browser Streamlit 🎈🚀
https://github.com/whitphx/stlite
hacktoberfest in-browser pyodide python serverless streamlit wasm web-assembly webassembly
Last synced: 17 days ago
JSON representation
In-browser Streamlit 🎈🚀
- Host: GitHub
- URL: https://github.com/whitphx/stlite
- Owner: whitphx
- License: apache-2.0
- Created: 2022-05-14T06:10:07.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-04-25T09:39:59.000Z (9 months ago)
- Last Synced: 2025-04-25T10:43:41.605Z (9 months ago)
- Topics: hacktoberfest, in-browser, pyodide, python, serverless, streamlit, wasm, web-assembly, webassembly
- Language: TypeScript
- Homepage: https://edit.share.stlite.net
- Size: 1.1 GB
- Stars: 1,380
- Watchers: 13
- Forks: 74
- Open Issues: 80
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Stlite: In-browser Streamlit
**Serverless [Streamlit](https://streamlit.io/) Running Entirely in Your Browser**
[](https://github.com/whitphx/stlite/actions/workflows/test-build.yml)
[](https://github.com/whitphx/stlite/actions/workflows/postbuild.yml)
This project is tested with BrowserStack.
[](https://www.npmjs.com/package/@stlite/browser)
[](https://www.npmjs.com/package/@stlite/desktop)
[](https://www.npmjs.com/package/@stlite/react)

Streamlit is a Python web app framework for the fast development of data apps. This project is to make it run completely on web browsers with the power of [Pyodide](https://pyodide.org/), WebAssembly (Wasm)-ported Python.
## Try it out online (_Stlite Sharing_)
Visit [Stlite Sharing](https://edit.share.stlite.net/).
[
](https://edit.share.stlite.net/)
## Create a desktop app (`@stlite/desktop`)
See [`@stlite/desktop`](./packages/desktop/README.md).
## Integrate _Stlite_ into your React app (`@stlite/react`)
See [`@stlite/react`](./packages/react/README.md).
## Use _Stlite_ on your web page (`@stlite/browser`)
> [!NOTE]
> Since 0.76.0, `@stlite/mountable` is renamed to `@stlite/browser`, and the API is changed. See the [Migration guide](./CHANGELOG.md#how-to-migrate-from-stlitemountable-to-stlitebrowser) for the details.
You can use _Stlite_ on your web page loading the script and CSS files via `` and `<link>` tags as below.
Here is a sample HTML file.
```html
<!doctype html>
<html>
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, shrink-to-fit=no"
/>
<title>Stlite App</title>
<link
rel="stylesheet"
href="https://cdn.jsdelivr.net/npm/@stlite/browser@0.85.1/build/stlite.css"
/>
<script
type="module"
src="https://cdn.jsdelivr.net/npm/@stlite/browser@0.85.1/build/stlite.js"
>
import streamlit as st
name = st.text_input('Your name')
st.write("Hello,", name or "world")