syntaqlite
SQLite SQL tools — parser, formatter, validator, and MCP server
Decision gist · record as of 2026-08-14
Yes. Syntaqlite is actively maintained, has no runtime dependencies, offers permissive licensing, and solves a real problem—accurate SQLite SQL parsing without approximations. The medium install friction (compiled wheels) is standard for performance-critical libraries. Install if you need to parse, validate, or analyze SQLite SQL in Python; skip if you only execute queries against a live database.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later.
- Medium install friction due to compiled wheels for multiple platforms (Linux x86_64/aarch64, macOS x86_64/arm64, Windows x86_64, WebAssembly).
- Active maintenance with recent releases; last commit 2026-07-08.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 permissive license allows commercial and private use with attribution; SQLite components are public domain under the SQLite blessing.
last release 2026-07-08 (37 days) · last repo commit 2026-07-08 · 797 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 367,937 downloads/mo, #7,193 on PyPI
Alternatives
Verify before relying
import syntaqlite
with syntaqlite.Syntaqlite() as sq:
formatted = sq.format_sql("select 1")
stmts = sq.parse("SELECT 1 + 2 FROM foo")
tokens = list(sq.tokenize("SELECT 1"))- Whether the AST node types and enums remain stable across minor version updates.
- Performance characteristics of parse_raw() vs typed parsing for large SQL batches.
- Whether schema analysis supports all SQLite pragmas and compile-time flags.
What it is and what it does
Syntaqlite is a Python library that parses, formats, validates, and tokenizes SQLite SQL using SQLite's own grammar and tokenizer—not an approximation, but the actual SQLite parser. It provides a typed AST with IDE autocomplete, a formatter that normalizes SQL structure, a tokenizer that breaks queries into categorized tokens, and schema-aware analysis that catches unknown tables, columns, and function mismatches without touching a database. It also computes column lineage to trace where output columns originate from source tables.
The library is built around a reusable `Syntaqlite` instance and exposes both typed Python objects (for safety and IDE support) and raw dict output (for performance). It includes a CLI tool for formatting, parsing, and validating SQL files, with support for pinning to specific SQLite versions and enabling compile-time flags. Zero runtime dependencies and wheels for Linux, macOS, Windows, and WebAssembly.
Use it for
- Format and normalize SQL queries in applications or CI pipelines to enforce consistent style without a database.
- Validate user-submitted SQL against a schema to catch typos and unknown columns before execution.
- Build linters or IDE plugins that need accurate SQLite syntax understanding and error reporting.
- Extract column lineage from SELECT queries to understand data provenance in ETL or analytics systems.
- Tokenize and analyze SQL for query optimization, cost estimation, or security scanning.
- Embed SQL parsing in tools that generate or transform SQLite queries programmatically.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Syntaqlite is actively maintained, has no runtime dependencies, offers permissive licensing, and solves a real problem—accurate SQLite SQL parsing without approximations. The medium install friction (compiled wheels) is standard for performance-critical libraries. Install if you need to parse, validate, or analyze SQLite SQL in Python; skip if you only execute queries against a live database.
Install
syntaqlite on PyPI
Before you install
Medium install friction due to compiled wheels for multiple platforms (Linux x86_64/aarch64, macOS x86_64/arm64, Windows x86_64, WebAssembly). Active maintenance with recent releases; last commit 2026-07-08.
Requires Python 3.10 or later.
License in practice
Apache-2.0 permissive license allows commercial and private use with attribution; SQLite components are public domain under the SQLite blessing.
Quickstart
import syntaqlite
with syntaqlite.Syntaqlite() as sq:
formatted = sq.format_sql("select 1")
stmts = sq.parse("SELECT 1 + 2 FROM foo")
tokens = list(sq.tokenize("SELECT 1"))
Verify before relying
- Whether the AST node types and enums remain stable across minor version updates.
- Performance characteristics of parse_raw() vs typed parsing for large SQL batches.
- Whether schema analysis supports all SQLite pragmas and compile-time flags.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Medium. Platform-specific wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 37 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 367,937 / month, #7,193 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
Evidence: syntaqlite-0.7.1-py3-none-macosx_10_13_universal2.whl; syntaqlite-0.7.1-py3-none-macosx_11_0_universal2.whl; syntaqlite-0.7.1-py3-none-manylinux_2_28_aarch64.whl; syntaqlite-0.7.1-py3-none-manylinux_2_28_x86_64.whl; syntaqlite-0.7.1-py3-none-pyemscripten_2026_0_wasm32.whl; syntaqlite-0.7.1-py3-none-win_amd64.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “sqlite sql parser”
- syntaqliteParse, format, validate, and tokenize SQLite SQL using SQLite's own…
- tree-sitter-sqlProvides a tree-sitter SQL grammar for parsing SQL code into an…
- dirsqlWatches a local directory, indexes structured files into an in-memory…
Give your agent the search over MCP, or paste the wish link into any chat.
More Database packages
psycopg2-binary is a PostgreSQL database adapter for Python that implements the DB API 2.0 specification, enabling Python applications to connect to and query PostgreSQL databases with thread-safe concurrent operations.
Python client library for connecting to and executing commands against Redis key-value stores, supporting both synchronous and asynchronous operations.
Install it if your application needs to interact with Redis; the only prerequisite is a running Redis server instance.
YDB Python SDK is the official client library for connecting to and querying YDB databases from Python applications.
Install it if you need to connect Python applications to YDB databases.
Connects Python applications to Snowflake data warehouses using the DB API 2.0 specification, enabling SQL queries, data transfers, and warehouse operations.
sqlparse tokenizes SQL text into a tree of statements, clauses, and expressions, and provides functions to split scripts, format queries, and inspect parsed tokens without validating dialect or syntax.
Install it if you need to manipulate, format, or analyze SQL text programmatically.
Provides base adapter protocols and shared functionality that database adapters use to integrate with dbt-core, handling connections, dialect translation, relation caching, and core interface management.
See also promql-parser · sqllineage · collate-sqllineage · tree-sitter-sql · sqlvalidator · sqlite-utils · parso · cql2 · sqlite-fts4