supabase/splinter(opens in a new tab)
Language: PLpgSQL
Supabase Postgres Linter: Performance and Security Advisors
- stars
- 284
- watchers
- 23
- forks
- 110
- open issues
- 55
- Last updated
- 10/30/2026
Language: PLpgSQL
Supabase Postgres Linter: Performance and Security Advisors
Documentation: https://supabase.github.io/splinter
Source Code: https://github.com/supabase/splinter
Splinter maintains a set of lints for Supabase projects. It uses SQL queries to identify common database schema issues. Some lints are general purpose for Postgres projects while others are specific to Supabase features storing their data in Postgres e.g. auth and storage.
If you are only interested in linting a project, a single query containing the latest version of all lints is availble in splinter.sql in the repo root.
Several lints (e.g. auth_users_exposed, materialized_view_in_api, foreign_table_in_api) only report objects that are reachable through the Data API — that is, objects in a schema listed in the pgrst.db_schemas setting. PostgREST sets this value at runtime, but it is not present in a plain psql connection.
When pgrst.db_schemas is unset, these lints default to the public schema only. If your project exposes additional schemas, set the value to match your PostgREST config before running the lints so those schemas are covered too:
set pgrst.db_schemas = 'public, graphql_public, ...';
Without this, exposures in non-public schemas will not be reported.
Each lint creates a view that returns a common interface. The interface is:
To deploy lints to Supabase prod, open a PR against supabase/supabase updating the lint query
If the update includes a new lint, update getHumanReadableTitle and LINT_TYPES.
To add a new lint using Claude Code, run the /new-lint skill from the .claude/skills/new-lint directory. It will guide you through creating the SQL view, test cases, and documentation.
Supabase PostgreSQL 15+
Setup:
git clone https://github.com/supabase/splinter.git
cd splinterThe docs use MkDocs with the Material theme. To install dependencies and serve the site with live reload:
python3 -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate pip install mkdocs-material mkdocs serve
Then open http://127.0.0.1:8000. Run mkdocs build to output static files to site/.
All lints tests with a true positive example.
To run the test suite:
docker rmi -f dockerfiles-test && SUPABASE_VERSION=15.1.1.13 docker-compose -f dockerfiles/docker-compose.yml run --rm test