panel-live¶
Write, edit, and run Python interactively in the browser — no server required.
Turn any web page into an interactive Python playground with the <panel-live> web component. Works with matplotlib, pandas, scikit-learn, Panel, and 200+ packages from the Python ecosystem. Visualizations, analyses, dashboards, and interactive tools are fully interactive — users can view, explore, edit code, and re-run, all directly in the browser via Pyodide — no backend, no deployment, no infrastructure.
Try it¶
App Mode¶
The default mode renders your Panel app directly — no editor, just the output.
Works with any Python¶
Not just Panel — run any Python code directly in the browser. Here's a matplotlib visualization with no Panel imports at all:
Click the Code button to edit the code and rerun it live in your browser!
Try changing the code to:
Perfect for library developers and educators who want to make it easy to explore, learn, and have fun.
Editor Mode¶
Edit the code below and press Run to see your changes.
Playground Mode¶
A side-by-side editor and live preview. Edit the code on the left and press Run.
Playground¶
Explore the full-screen Playground — a curated collection of interactive examples you can edit and run instantly.
API Editor¶
Explore and configure every <panel-live> attribute interactively with the API Explorer.
Features¶
- 3 modes: app (output only), editor (code + output), playground (side-by-side)
- Web Worker execution — Pyodide runs in a Dedicated Worker, keeping the page responsive
- Light / dark / auto theming that follows the host page
- CSS custom properties for full branding control
- Real-time print output —
print()streams incrementally as code executes - Multi-file support via
<panel-file>child elements - Explicit requirements via
<panel-requirements> - MkDocs integration via fenced code blocks and
pymdownx.superfences - No server needed — runs entirely in the browser via Pyodide
Known Limitations¶
Because panel-live runs entirely in the browser via Pyodide (WASM), some features that require a live server are not available:
- No
.plot()calls — matplotlib'splt.show(), plotly'sfig.show(), and similar display methods do not work. Instead, return the figure object as the last expression (e.g.fig) and panel-live will render it. - No
.show()calls — Bokeh'sshow(), Panel's.show(), and similar server-dependent methods are not supported.
For a full list, see Known Limitations.
Get Started¶
- Examples — interactive examples across all categories
- Playground — full-screen editing environment
- API Explorer — configure every attribute interactively
- How-to Guides — per-attribute guides with live examples
- Reference — complete HTML, JavaScript, CSS, and Events API
- Design Decisions — why panel-live is built the way it is