Python Compiler

Write Python and run it. Real CPython in your browser - no install, no account, nothing sent to a server.

Updated

main.py Python 3
Output

                

What this is

CPython compiled to WebAssembly, running on your own machine. Your code is never uploaded, and the page works offline once it has loaded the interpreter.

The first Run takes a few seconds while the interpreter downloads. Every run after that is immediate.

What works

  • The standard library — math, json, re, collections, itertools, datetime and the rest.
  • print, f-strings, comprehensions, classes, generators.
  • Tracebacks, in full. A mistake here reads exactly as it would in a terminal.

What does not

  • input() — there is no stdin to read from.
  • Reading or writing files on your computer.
  • Network calls, and packages that need to be installed.

Learning Python?

The Python track teaches it one idea at a time, each with an editor like this one beside the explanation — starting at your first print statement.