Playground

Run the published package without installing Python. The playground starts a private Python session in your browser, installs PyWorldAtlas from PyPI, and keeps that session alive while you explore.

Python in your browser

Explore the atlas

Look up any country or place, take a quiz, or choose one of twenty-one complete recipes and write your own Python. Press Ctrl/⌘ + Enter to run it.

Preparing Python…
Python starting PyWorldAtlas 0.13.1 Dataset bundled Recipes 21 ready

Look up anything

    Quiz me

    Five questions about countries, flags, and famous places. Every answer comes from the atlas.

    Ready-to-run recipe library

    world_snapshot.py
    Your session persists between runs.
    Output
    Python is starting. The first load can take a moment.

    What is running?

    This is the real pyworldatlas==0.13.1 wheel published on PyPI, not a JavaScript imitation or a remote demonstration API. Pyodide runs CPython in WebAssembly, while a module Web Worker keeps execution away from the page’s interface. After startup, country queries read the same bundled SQLite database used by a normal installation.

    The first visit downloads the Python runtime from a pinned public CDN, with a second provider available if the first cannot be reached, and the wheel from PyPI. Code entered in the editor is evaluated on your device; this project does not receive its contents. Each run has a 20-second safety limit, and interactive input() calls are not supported.

    Place, city, and country data come from GeoNames (CC BY 4.0) and Unicode CLDR (Unicode License v3), among other credited sources; see Data sources and freshness.

    Things worth trying

    Look up anything answers in plain cards: type a country, city, mountain, lake, or landmark. Each card has Open in the editor, which loads the Python that produced it, so you can see how it works and change it. Surprise me picks a famous place, and Quiz me asks five questions with a score.

    The twenty-one guided programs cover six different ways to use the package:

    • Meet the world: summarize the atlas, build a rich country dossier, compare profiles, and cross original writing systems.

    • Measure and connect: calculate distance, bearing, and midpoint; locate nearby capitals; follow a land-border path; and connect profiles through source-listed rivers and lakes.

    • Analyze the atlas: build multi-metric leaderboards, visualize represented climate shares, inspect populated places, and combine search with filters.

    • Learn and build: generate repeatable quiz material and export portable, Unicode-preserving JSON.

    • Every place on Earth: search 200,000 places by name, see what is nearby, work out sunrise and day length anywhere, and compare travel basics.

    • Challenges: find the capital with the shortest December day, the capital closest to the equator, and the two capitals farthest apart.

    Change a country name, adjust a ranking, or combine two examples. The Python session persists until you select Reset Python or close the page. The Example programs page presents the strongest programs as normal copy-ready Python alongside direct links back to the matching interactive recipe.

    Use the package locally

    For projects, notebooks, and unrestricted sessions, install the package in a normal Python environment:

    python -m pip install pyworldatlas
    

    Then continue with the Quickstart or the complete API reference reference. Local installations need no network connection at runtime.