Pulse Data Hub

Tools / Python and SQL Playground

Python and SQL Playground

Write Python or SQL and run it right here in your browser. pandas, NumPy, Matplotlib and scikit-learn are ready to import, two sample datasets are loaded, and the SQL tab comes with a sample database. Nothing to install, no sign-up, and your code never leaves your computer.

Ctrl + Enter to run
Output
Files you can read: tips.csv (244 restaurant bills) and penguins.csv (344 penguins)
Tables in the Chinook database
  • Loading…

How to use the playground

Pick Python or SQL, write your code (or choose an example from the menu) and press Run, or Ctrl + Enter (Cmd + Enter on a Mac). Output appears on the right, or below the editor on a phone.

  • Python prints whatever you print(). If the last line is an expression, its value is shown too, as in Jupyter, so a pandas DataFrame on the last line appears as a table. Charts made with Matplotlib show up as images when you call plt.show().
  • SQL runs every statement in the editor and shows a table for each query, up to 500 rows each. Tables you create stay until you press Reset database or reload the page.
  • Your code is saved in your browser, so it’s still there when you come back. Press Stop if something runs for too long.

What’s available

TabWhat you get
PythonPython 3.14 running on Pyodide. The standard library works, and pandas, NumPy, Matplotlib, SciPy, scikit-learn and statsmodels load automatically when you import them. The first run downloads Python (about 10 MB), and each library downloads the first time you import it; after that your browser caches them.
Python datatips.csv: 244 restaurant bills with tip, day, time and party size. penguins.csv: 344 Palmer penguins with bill, flipper and body-mass measurements (some values missing). Both come from the seaborn sample data.
SQLSQLite, running on sql.js, with the Chinook sample database: a fictional music store with 11 tables (customers, invoices, tracks, albums, artists, genres and more) and 412 invoices. Window functions, CTEs and strftime() date functions all work.

Limits

  • input() doesn’t work. Put the value in your code instead.
  • Python here runs inside the browser, so libraries that need a GPU or native system access, such as TensorFlow and PyTorch, aren’t available. Reading files from your own computer isn’t supported yet.
  • Heavy work is slower than on your own machine, often two to five times. It’s fine for learning and for datasets of a few hundred thousand rows.
  • Output stops after 200,000 characters, and SQL results show the first 500 rows of each query.

Frequently asked questions

Is this playground free?

Yes. There’s no account and no limit on how often you run code.

Is my code sent to a server?

No. Python and SQLite are downloaded to your browser and your code runs there. Nothing you type is uploaded or stored by Pulse Data Hub.

Can I use pandas and Matplotlib online without installing Python?

Yes, that’s what the Python tab is for. Import them as usual; the playground downloads them the first time.

Which SQL dialect does it use?

SQLite (version 3.54). Most of what you’d write for PostgreSQL or MySQL works, including joins, CTEs and window functions. A few things differ: dates are stored as text and handled with strftime(), and there’s no ILIKE or DATE_TRUNC().

Why is the first run slow?

The first time, your browser downloads Python and the libraries you import. Later runs, and later visits, use the cached copy and start in a second or two.


Keep learning

Verified by MonsterInsights