Skip to main content

Ruff Playground — Online Ruff Linter, Formatter & AST

playground.pyloading Ruff…
import os, sys
from typing import List

def greet(names:List[str])->None:
    for n in names:
        msg = f'Hello, {n}!'
        print( msg )

greet(["world","ruff"])
168 chars | 9 lines
| Loading the Ruff engine…
Official Ruff 0.16.2 WebAssembly build — diagnostics, formatting, AST, tokens and the formatter IR run locally in your browser. Edit the settings, share a link to your snippet, updates live as you type.

Ruff Playground — Online Ruff Linter, Formatter & AST

Want to check Python with Ruff online without installing anything? Paste your code and this playground runs ruff check live — diagnostics, formatting, the AST, tokens and formatter IR all update as you type. It runs the official Ruff WebAssembly build entirely in your browser, and you can share a link that reopens your exact code and settings.

Tool facts

Supported Python
Python 3.7 – 3.14
Input limit
Limited only by your device
Last reviewed
2026-08-25

What it can't do

  • Execute your code — Ruff is a static linter and formatter.
  • Replace a type checker for cross-module type inference.

About Ruff Playground

This is a full, professional-grade playground for Ruff, the extremely fast Rust-based Python linter and formatter from Astral. It updates live as you type: pick a tab to see the lint diagnostics (ruff check), the formatted output (what ruff format would produce), the parsed AST, the raw token stream, the formatter's intermediate representation (IR), or the extracted comments. A light/dark theme toggle keeps the editor comfortable in any lighting.

**How to check Ruff online, step by step:** (1) Paste or type your Python into the editor — syntax highlighting and live linting start immediately. (2) Read the **Diagnostics** tab: each issue shows its rule code (e.g. F401 unused import, E701 multiple statements), line and column, and whether Ruff can auto-fix it. (3) Switch to **Formatted** to see the ruff format output, or **AST** / **Tokens** / **Formatter IR** to inspect how Ruff parses your code. (4) Open **Settings** to edit the Ruff config as JSON — the same fields you'd put under [tool.ruff] in pyproject.toml, including select, ignore, line-length and format.quote-style. (5) Hit **Share** to copy a link that reopens your exact code and settings.

Because it runs the official Ruff build compiled to WebAssembly (currently Ruff 0.16.2), everything happens locally in your browser. For a quick one-click lint or format without the extra views, use the simpler Ruff Linter & Formatter instead.

For a project-level decision, see our Ruff vs Pylint comparison tested on the same code. It shows which of 14 error categories each tool caught, what Ruff fixed automatically, measured CLI timings, and when Pylint's semantic and cross-file analysis still matters.

Frequently Asked Questions

Paste your Python into the editor above — it runs `ruff check` live in your browser and shows every diagnostic with its rule code, line and column, and whether it's auto-fixable. There's nothing to install; it runs the official Ruff WebAssembly build locally in your browser. Switch tabs to also see the formatted output, AST, tokens and formatter IR.