PyScript lets you run Python in the browser, but large runtimes, main-thread blocking, and client-side trust issues require deliberate architecture. Choose the smallest runtime, offload compute to a Web Worker, and keep secrets on the server.
Learn how to use PyScript and Pyodide to manipulate the DOM and create reactive web interfaces using Python, including a practical example of event handling and performance trade-offs.
PyScript's <py-config> tag declares Python packages in TOML/JSON; micropip installs WASM wheels at load time, caching them in IndexedDB. Works for pure-Python and Pyodide-built binaries, but lacks full dependency resolution and fails on missing wheels.
Learn how to load external Python packages in the browser using PyScript’s <code><py-config></code> tag, with a hands‑on example, performance trade‑offs, and a practical checklist for production.
A decision guide for picking Pyodide or MicroPython in PyScript: compare bundle size, startup time, package availability, threading, and JavaScript interop. Includes minimal working HTML for each runtime and a validation checklist using browser DevTools.
How to declare Python dependencies in PyScript's py-config, which packages actually load in the Pyodide runtime, and the compatibility and performance limits that decide whether PyScript fits your project.
A diagnostic guide for troubleshooting PyScript initialization failures, focusing on Pyodide WASM loading, COOP/COEP headers, and configuration sequencing.
Choose between static preload via py-config and dynamic micropip install in PyScript. Compare startup latency, bundle size, offline use and maintenance, with concrete HTML examples and a validation approach.