Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

docs: molab (#8554)

Akshay Agrawal73797a7c9f18
diff --git a/docs/guides/molab.md b/docs/guides/molab.md
index 91243095a4..0b1454f081 100644
--- a/docs/guides/molab.md
+++ b/docs/guides/molab.md
@@ -1,66 +1,262 @@
-# Share cloud notebooks with molab
+# Run in the cloud with molab
-[molab](https://molab.marimo.io/notebooks) is a cloud-hosted marimo notebook
-workspace that lets you rapidly experiment on data using Python and SQL. We’re
-giving molab (**mo** for marimo) to you, our community, for *free*.
+!!! tip "Contribute to our community gallery!"
+ We welcome submissions to our curated [community gallery](https://marimo.io/gallery?tag=community).
+ To propose an example, [reach out to us on Discord](https://marimo.io/discord).
-To create your first notebook, visit:
-[https://molab.marimo.io/notebooks](https://molab.marimo.io/notebooks).
+[molab](https://molab.marimo.io/notebooks) is a free cloud-hosted marimo notebook
+environment: run notebooks on cloud machines from your browser, zero setup required.
+molab also integrates with GitHub, and supports embedding notebooks in other
+webpages, making it easy to share your work.
-!!! tip "Contribute example notebooks!"
- We welcome exciting companies and projects to contribute examples notebooks,
- which are featured on the homepage with an organization's name and logo. To propose an example,
- [reach out to us on GitHub](https://github.com/marimo-team/marimo/issues).
+> Visit [https://molab.new](https://molab.new) to instantly create a new notebook.
+
+molab notebooks are public but undiscoverable by default.
**Highlights**.
-- ⚡️ Build powerful notebooks using [marimo](https://github.com/marimo-team/marimo), a next-gen open-source Python notebook built entirely from scratch that [solves](https://marimo.io/blog/lessons-learned) [long-standing](https://marimo.io/blog/python-not-json) [problems](https://leomurta.github.io/papers/pimentel2019a.pdf) with Jupyter
-- ☁️ Use any Python package, thanks to our cloud backend
+- ☁️ Use any Python package
- 🤖 Generate code with AI
-- 📦 Upload data files
-- 🔗 Share links and badges (notebooks are public but undiscoverable, like secret GitHub Gists)
+- 📦 Install packages with a built-in package manager
+- 🛢️ Use a limited amount of persistent storage per notebook
+- 🔗 Share links and open-in-molab badges
+- 🌐 Embed interactive notebooks in your own webpages
- 📥 Download notebooks to your machine, reuse them as Python scripts or apps
- 📤 Upload local notebooks to the cloud from our CLI (coming soon)
- 🕹️ Real-time collaboration (coming soon)
- 🧩 Configure computational resources to obtain more CPU or GPU (coming soon)
-
## Sharing
-molab notebooks are public but undiscoverable by default.
+To share notebooks created in molab, just share the notebook's URL. Viewers
+will see a static preview of your notebook and the option to fork it into their
+own workspace.
+
+### Preview notebooks from GitHub
+
+In addition to sharing notebooks created in your workspace, you can also
+preview notebooks hosted on GitHub. In some cases, these previews can be
+interactive, but they are static by default.
+
+#### Static previews
+
+
+> Visit [molab.marimo.io/github](https://molab.marimo.io/github) to automatically generate preview URLs from GitHub links.
-### URL
+To construct a static (read-only, not interactive) preview, replace `github.com` in your notebook's GitHub URL
+with `molab.marimo.io/github`. For example, a notebook at
-You can share notebooks by URL. Here's an example:
+```
+https://github.com/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py
+```
+
+becomes
-> https://molab.marimo.io/notebooks/nb_TWVGCgZZK4L8zj5ziUBNVL
+```
+https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py
+```
-### Open in molab badge
+#### Interactive previews
+
+Interactive previews let viewers run and interact with your notebook before
+forking it. Append `/wasm` to the static preview URL to construct an
+interactive preview. For example:
+
+```
+https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py/wasm
+```
+
+Your notebook must be [WebAssembly-compatible](wasm.md) for interactive
+previews to work, and we also recommend creating these notebooks
+[with `--sandbox`](package_management/inlining_dependencies.md)
+to make sure their dependencies get installed. If you use coding
+agents like Claude Code, you can use our [official
+skills](generate_with_ai/skills.md) to automatically check for WebAssembly
+compatibility of your notebooks.
+
+### Share open-in-molab badges
Share links to molab notebooks using our open in molab badge:
-[![Open in molab](https://marimo.io/molab-shield.png)](https://molab.marimo.io/notebooks/nb_TWVGCgZZK4L8zj5ziUBNVL)
+[![Open in molab](https://marimo.io/molab-shield.svg)](https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py)
Use the following markdown snippet (replace the notebook URL with a link to your own notebook):
+```markdown
+[![Open in molab](https://marimo.io/molab-shield.svg)](https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py)
```
-[![Open in molab](https://marimo.io/molab-shield.png)](https://marimo.io/notebooks/nb_UJPnqcQzB7NuTtVNhwYBBp)
+
+For notebooks hosted on GitHub, use our [badge
+generator](https://molab.marimo.io/github) to automatically generate embeddable
+links. If you want the preview to be interactive (and if your notebook is
+[WebAssembly-compatible](wasm.md)), append `/wasm` to the URL.
+
+## Embed in other webpages
+
+You can embed interactive molab notebooks in your own webpages using iframes.
+Embedded notebooks run in the browser via WebAssembly, so your notebook must
+be [WebAssembly-compatible](wasm.md). We also recommend creating these
+notebooks [with `--sandbox`](package_management/inlining_dependencies.md) to make sure their dependencies get installed.
+
+### Embed notebooks from GitHub
+
+Add `?embed=true` to an [interactive preview URL](#interactive-previews) to get an embeddable notebook:
+
+/// tab | Code
+
+```html
+<iframe
+ src="https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py/wasm?embed=true"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+>
+</iframe>
```
-## Packages
+///
+
+/// tab | Live Example
+
+<div class="demo-container">
+ <iframe
+ src="https://molab.marimo.io/github/marimo-team/gallery-examples/blob/main/notebooks/math/cellular-automaton-art.py/wasm?embed=true"
+ class="demo large"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+ >
+ </iframe>
+</div>
+
+///
+
+### Embed from source code
+
+You can embed a notebook directly from its source code, without hosting it on
+GitHub. Compress your notebook code using
+[lz-string](https://www.npmjs.com/package/lz-string) and pass it as a URL
+hash:
+
+```
+https://molab.marimo.io/new/wasm/#code/{compressed}
+```
+
+For example, in JavaScript:
+
+```javascript
+import { compressToEncodedURIComponent } from "lz-string";
+
+const url = `https://molab.marimo.io/new/wasm/#code/${compressToEncodedURIComponent(code)}`;
+```
+
+Query parameters go before the hash:
+
+```
+https://molab.marimo.io/new/wasm/?embed=true#code/{compressed}
+```
+
+For small notebooks (under 14 KB), you can also use the `code` query parameter
+with URI encoding instead of lz-compression:
+
+```
+https://molab.marimo.io/new/wasm/?embed=true&code={encodedURIComponent}
+```
+
+/// tab | Code
+
+```html
+<iframe
+ src="https://molab.marimo.io/new/wasm/?embed=true#code/MQAg9BIM4MYE4EsAOAXAUKOBTAjgVwWygFokBPFACwHsA7EAXhACIA+BgZgDoBGABmYYQAEyxIstUbRgIsURiADaQkKpYBbAIaJ11ZgBoVa5lpRIANtRTmEAIwNHVzWnnXkHoNS1jIyHkAC6QhBgaGgIbtRwKCBaOtRhAPqJAOYSWHCaKFjCiQDuCFQKzHxcAEylZYKaSEgKcRHUXACCtQAUaF4wUFCJAGYI5lgMzGB4UHBgljCa5mCJDbpgMOMo1Opc3VAOXpp4a4nC1Hm0lprCDIrMlCjq5swBhgCUYQVFNUhcUFgoeEgAXJ01BEkFEYotqCBNPJdEDVCCwSAXG4yFD5LQkHCQAjorEshYrDZbFxyASYtCQBZ0F4+nB1nizJZrHZNtRLHB5DiYgAZBC0LDaADKWBS6gk2WEAGE2VEtEh9CBeVAJdL2XKsbT6T5yFxJBFNGlsZFcTA6AA3NlmrAKlJ7HoITS0fqDbJwMJoAACH02WHM5jalAQokSptEDAAKnA8FgXqI+iBEm0noCvLouOphG1mNmsaBJb7zHhzNoQM19ussnRS9Ewl5w4H0VYsLZqNQANbQCJFrJyKEgGAF7twKHl0xV8Z8lJ9i2u2LUUTmBWO4Qgca9qhYLFEIsxNZ4ttYKG4t6UBlkolcEAASRieQpfKgSEIORAtlRikdR5iT6wA4CAZQMwoH+CAAA9WXUMBBUSaVa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6oLTMBmj-FbIrK7KDD6bTr+TMAoB7KQnMCFFeDzE1HZppDlx9ptCfGOS0BcBon16N4rLAmTRbJK5570BTGj46yxqKDImLHLFaCrEgDrHg40Ta67H0D7E45HHmyejejYa4Z7r4ZmpKKWpDz+Q2YSZwBSZAZCTjDcbUaMY9jMaKrt5ia6jCCSZuq95iwaTEADDOYZD+SVbFgDgm6VyniXwT6FCng0K6DKhKbqC6D0CTxw5ZxtBlBwCarPbqoelek0QFAaZ5Db6CBeA+ZsTjCMBMB8CVEoYF5eAHiyQULlafDBz5rukgAz7hnyA5YKhlAZkHyynZk6qkldCMJlzHZqngptiY6qAuF3Smi0AWjmBWhtDKqRnQAiTQgoBkDiDGxnAoCVoJn8iLhzhhjMCYo1Azr8Ha6cgcnY716KmVSXpQ5qBCITH0A2baCihqptCmg4ZHYJ4VpcBdk9k1x8LCDdniA8mWxF4Cl0BV60qimTTiniYalSlurJbbn+R9D9kKmTzKllyqkSlvlSbakRLjBRJsExJmnyYulVyOjDnL4SAHxYDED4COiORzRXFIUiDrB8gYUlI9jBlFHxjTTbntnRkcyxm55Im0rYAmqVmNQQocx1mjS2gQUOhOj6mug1l3Rtnu4dnHnKinl9nUBZAE5ppaAMBkVaAKi6BjkTlIAhn8GXrQ7DizkFkqI46LlyDLkaxklqlbkMmYl0U5CHmdnCW9nnmXmOxhA+bJA9HJDtnMDJBaB8jJB+RJKKRRil4vBAA"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+>
+</iframe>
+```
+
+///
+
+/// tab | Live Example
+
+<div class="demo-container">
+ <iframe
+ src="https://molab.marimo.io/new/wasm/?embed=true#code/MQAg9BIM4MYE4EsAOAXAUKOBTAjgVwWygFokBPFACwHsA7EAXhACIA+BgZgDoBGABmYYQAEyxIstUbRgIsURiADaQkKpYBbAIaJ11ZgBoVa5lpRIANtRTmEAIwNHVzWnnXkHoNS1jIyHkAC6QhBgaGgIbtRwKCB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yqkSlvlSbakRLjBRJsExJmnyYulVyOjDnL4SAHxYDED4COiORzRXFIUiDrB8gYUlI9jBlFHxjTTbntnRkcyxm55Im0rYAmqVmNQQocx1mjS2gQUOhOj6mug1l3Rtnu4dnHnKinl9nUBZAE5ppaAMBkVaAKi6BjkTlIAhn8GXrQ7DizkFkqI46LlyDLkaxklqlbkMmYl0U5CHmdnCW9nnmXmOxhA+bJA9HJDtnMDJBaB8jJB+RJKKRRil4vBAA"
+ class="demo large"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+ >
+ </iframe>
+</div>
+
+///
+
+### Embed an empty editable notebook
+
+Use this recipe to embed an empty editable notebook:
+
+/// tab | Code
+
+```html
+<iframe
+ src="https://molab.marimo.io/new/wasm/?embed=true&mode=edit#code/JYWwDg9gTgLgBCAhlUEBQaD6mDmBTAOzykRjwBNMB3YGACzgF44AiAVwIGsCIqCW0iMGCYJkqAHQBBYQAoAlBjQABIWAkBjPABttacngBmcTAoBcaOFbhQ8MNlAJLgx7AUQg82JsxbYkwATYLBbWcGoSUBwKaEA"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+>
+</iframe>
+```
+
+///
+
+/// tab | Live Example
+
+<div class="demo-container">
+ <iframe
+ src="https://molab.marimo.io/new/wasm/?embed=true&mode=edit#code/JYWwDg9gTgLgBCAhlUEBQaD6mDmBTAOzykRjwBNMB3YGACzgF44AiAVwIGsCIqCW0iMGCYJkqAHQBBYQAoAlBjQABIWAkBjPABttacngBmcTAoBcaOFbhQ8MNlAJLgx7AUQg82JsxbYkwATYLBbWcGoSUBwKaEA"
+ class="demo large"
+ sandbox="allow-scripts allow-same-origin allow-downloads allow-popups"
+ allow="microphone"
+ allowfullscreen
+ loading="lazy"
+ >
+ </iframe>
+</div>
+
+///
+
+### Query parameters
+
+| Parameter | Default | Description |
+| --- | --- | --- |
+| `embed=true` | `false` | Hides the molab header for a cleaner embed |
+| `mode=edit` | `read` | Allows viewers to edit code cells |
+| `include-code=false` | `true` | Excludes code entirely (only works with `mode=read`) |
+| `show-code=false` | `true` | Hides code by default, but viewers can still reveal it |
+
+
+## Features
+
+### Package management
Each notebook runs in an environment with several popular packages
pre-installed, including torch, numpy, polars, and more. marimo’s built-in
package manager will install additional packages as you import them (use the
-package manage panel to install specific package versions).
+package manager panel to install specific package versions).
-## Storage
+### Storage
-Notebooks get persistent storage; view the file tree by clicking the file icon
-in the sidebar. From here you can upload additional data files, which are
-stored in a Cloudflare R2 bucket.
+Notebooks get a limited amount of persistent storage; view the file tree by
+clicking the file icon in the sidebar. From here you can upload additional data
+files.
-## Run notebook locally
+### Run notebooks locally
You can download the notebook directory by clicking the download button, also
on the top-right. You can also just pass the notebook URL to marimo edit. For
@@ -70,27 +266,28 @@ example:
marimo edit https://molab.marimo.io/notebooks/nb_TWVGCgZZK4L8zj5ziUBNVL
```
-Today, this brings just the notebook file down, and does not include your attached storage.
+Currently, this brings just the notebook file down, and does not include your attached storage.
## FAQ
-**What’s the difference between molab and Google Colab?** Google Colab is a hosted Jupyter notebook service provider. molab is a hosted [marimo notebook](https://github.com/marimo-team/marimo) service with similar compute and sharing capabilities, but powered by marimo notebooks instead of Jupyter.
-
-**Is molab marimo’s enterprise product?** No. If you’re interested in a
-next-generation data platform for modern AI and data workloads — with marimo’s
-trademark developer experience, complete with security and governance required
-for enterprises — [get in touch](mailto:[email protected]).
-
-**Is molab free?** molab is currently free to use, as long as usage is reasonable. Our goal is to make is as easy as possible for our community to use marimo notebooks.
+**What’s the difference between molab and Google Colab?** Google Colab is a
+hosted Jupyter notebook service provider. molab is a hosted [marimo
+notebook](https://github.com/marimo-team/marimo) service with similar compute
+and sharing capabilities, but powered by marimo notebooks instead of Jupyter.
+Unlike Colab, molab also supports embedding interactive notebooks in your own
+webpages, no login required.
-**How do I get more RAM, CPU or GPUs?** [Reach out to us](https://marimo.io/discord) and we’ll see what we can do!
+**Is molab free?** Yes.
-**I’m a compute provider. How do I get plugged into molab as an offered backend?** [Get in touch](mailto:[email protected]).
+**How do I get more RAM, CPU or GPUs?** [Reach out to us](https://marimo.io/discord) and we’ll see what we can do.
-**How does molab relate to marimo’s open source notebook?** molab is a hosted version of marimo’s open source notebook. You can use marimo on your own machine or on your own remote servers.
+**How does molab relate to marimo’s open source notebook?** molab is a hosted
+offering of marimo’s open source notebook with cloud-based compute and sharing
+capabilities. You can use marimo open source on your own machine or on your own remote
+servers.
-**How does molab relate to marimo’s WebAssembly playground?** The [WebAssembly playground](https://marimo.app) runs notebooks entirely in the browser through [Pyodide](https://pyodide.org/en/stable/). This makes for a snappy user experience, at the cost of limited compute and limited support for Python packages. The playground is well-suited for lightweight notebooks and embedding interactive notebooks in documentation, but it is not well-suited for modern ML or AI workflows. molab is currently entirely separate from the WebAssembly playground. In the future we may merge them into a unified experience.
+**I’m a compute provider. How do I get plugged into molab as an offered backend?** [Get in touch](mailto:[email protected]).
-**How does molab relate to marimo’s community cloud?** Our [community cloud](https://marimo.io/dashboard) provides a place to organize and share WebAssembly notebooks. molab is currently entirely separate from the community cloud. In the future we may merge them into a unified experience.
+**How does molab relate to marimo’s WebAssembly playground?** The [WebAssembly playground](https://marimo.app) runs notebooks entirely in the browser through [Pyodide](https://pyodide.org/en/stable/). This makes for a snappy user experience, at the cost of limited compute and limited support for Python packages. The playground is well-suited for lightweight notebooks and embedding interactive notebooks in documentation, but it is not well-suited for modern ML or AI workflows. molab bridges the gap: develop notebooks with the full power of Python running on a traditional server, and (when compatible) share interactive previews using WebAssembly, which others can fork and develop further using a server-backed notebook.
**Why are you making molab?** See our [announcement blog post](https://marimo.io/blog/announcing-molab).
diff --git a/docs/guides/wasm.md b/docs/guides/wasm.md
index 77d377ae73..eb7664be44 100644
--- a/docs/guides/wasm.md
+++ b/docs/guides/wasm.md
@@ -9,6 +9,11 @@ without a backend executing Python. marimo notebooks that
run entirely in the browser are called WebAssembly notebooks, or WASM notebooks
for short.
+!!! tip "Check for WebAssembly compatibility"
+ Not all notebooks are compatible with WebAssembly. If you use coding agents
+ like Claude Code, you can use our [official skills](generate_with_ai/skills.md)
+ to automatically check for WebAssembly compatibility of your notebooks.
+
!!! tip "Try our online playground"
To create your first WASM notebook, try our online playground
diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css
index d8b1e70ba4..5529beabe9 100644
--- a/docs/stylesheets/extra.css
+++ b/docs/stylesheets/extra.css
@@ -67,7 +67,7 @@ iframe.demo.medium {
}
iframe.demo.large {
- height: 600px;
+ height: 700px;
}
iframe.demo.xlarge {
@@ -91,3 +91,13 @@ video {
.examples-grid img {
max-height: 125px;
}
+
+.demo-container {
+ border-radius: 8px;
+ overflow: hidden;
+ box-shadow: 0 4px 5px rgba(0,0,0,0.08);
+ margin-top: 1rem;
+ margin-bottom: 1rem;
+ margin-left: 5%;
+ margin-right: 5%;
+}
diff --git a/mkdocs.yml b/mkdocs.yml
index fd18e05c61..e5de7db238 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -133,8 +133,8 @@ nav:
- Run notebooks as apps: guides/apps.md
- Run notebooks as scripts: guides/scripts.md
- Reuse functions and classes: guides/reusing_functions.md
+ - Run in the cloud with molab: guides/molab.md
- Export to other formats: guides/exporting.md
- - Cloud notebooks with molab: guides/molab.md
- Publish to the web:
- Publish to the web: guides/publishing/index.md
- Embedding: