Practice SQL online — free, no signup

SQLazo is a free SQL playground with a real database and 98 graded exercises. Write queries, get instant feedback, and follow a structured path from SELECT to window functions — all in your browser, no signup.

How practice works

Pick a topic

Start at the beginning or jump to what you need: filtering, joins, aggregates, subqueries, window functions…

Write a real query

The editor runs SQLite in your browser against a record-store database. No installation, no server, no account.

Get instant feedback

Every exercise is graded against a fresh database. If the rows match, it counts; hints and the full solution are one click away.

Start with a few exercises

Meet the artists

Every journey starts with a look around. Ask the artists table for everything it has — all columns, all rows.

Songs for a long drive

The boss is building a playlist for a long road trip and only wants the long songs. From tracks, get title and duration_sec for every tra…

Shortest first

The listening kiosk plays tracks from shortest to longest. Get title and duration_sec from tracks, sorted by duration, shortest first.

How big is the catalog?

Before we count money, let's count records. The owner wants a single number: how many tracks the store sells. Ask the tracks table.

Track to album

tracks only stores an album_id — a number that means nothing on its own. Join tracks with albums so that every row shows the track's titl…

The marathon queue

The store app is getting a "longest songs" screen. Number every track from 1 (longest) to 49 (shortest), ordering the results by duration…

What you can practice

Practice FAQ

Is SQLazo really free?

Yes — the whole course, all 98 exercises and every lesson, is free. No paywalls, no trials.

Do I need an account to use the site?

No. You can do the entire course without registering. An optional account (Google, GitHub or email) only saves your progress across devices.

Where does the SQL actually run?

In your browser. The database is SQLite running as WebAssembly (sql.js) — queries never leave your machine. There is no server processing your SQL.

How does the grader decide if my query is correct?

It runs your query against a fresh copy of the database and compares the result rows with the expected ones. Values must match; column names and row order are usually free.