Python in the browser
Run small programs locally with the bundled Pyodide runtime.
Try Python lists, write a function or experiment with async tasks. The interpreter runs in your browser with a console beside your code.
No account needed for browser-local experiments. Cloud saving is optional.
prices = [120, 80, 200]
total = sum(prices)
print(f"Total: {total}")Run small programs locally with the bundled Pyodide runtime.
Supply standard input and inspect source locations when an error is reported.
Optionally enable the bundled requests demo for approved JSONPlaceholder GET/HEAD requests.
Open the Python playground and wait for the runtime to initialize.
Edit the example and supply standard input if your program uses input().
Click Run; inspect the console or jump to an available error line.
Python runs as browser WebAssembly, not a full server environment. Arbitrary pip packages, operating-system access and unrestricted networking are unavailable. The optional API demo has an allowlist, request limits and a separate execution timeout.
Split the sentence on whitespace and count each word with a dictionary. Print the counts for code and learn.
Load the starterUse a list comprehension to build a list containing the square of every even number. Print the list.
Load the starterDefine average(numbers) so that it returns the mean of a list of numbers, and returns 0 for an empty list. Print the average of scores and of an empty list.
Load the starterFor each word, print True if it reads the same backwards when you ignore upper and lower case, and False otherwise.
Load the starterLocal drafts stay in this browser’s storage. Export a ZIP or source file to keep a separate copy. Cloud saves need a configured account and are sent to the site’s database.
Running code in this playground does not call an AI provider.
Use test data for experiments. Browser code, source exports, console messages, and debug reports can expose values you put in them.