๐Ÿš€ Get schema diff comments on every PR โ€” no YAML required

The GitHub App is in early access. Request an invite, or start automating schema diff checks in your pipeline today.

๐Ÿ”Œ Zero-config install

Install the app on your repo. It listens for pull requests and automatically comments the schema diff โ€” no workflow file needed.

โšก Instant PR feedback

Developers see added/removed/modified tables, breaking changes, risk score, and generated migration SQL right inside the PR.

๐Ÿ›ก๏ธ Built for security

Schema contents are read through GitHub's API, diffed in memory, and never stored. SchemaLens only needs read access to your SQL files.

๐Ÿ”ง Optional repo config

Add a .schemalens.json file to control which SQL file to diff and which dialect to use. Otherwise the app auto-detects from changed .sql files.

How it works

1

Install the app

Pick the repositories SchemaLens can access. The app subscribes to pull request events only.

2

Open a pull request

When a PR is opened or updated, SchemaLens reads your schema file at the base and head refs.

3

Review the comment

SchemaLens posts (or updates) a comment with the diff summary, breaking changes, risk score, and migration SQL.

๐Ÿ‘€ See the comment your team will get

SchemaLens posts a concise report directly on the pull request. Pick an example to preview what developers and reviewers see.

SL
SchemaLens Bot commented
on schema.sql

๐Ÿ” SchemaLens Schema Diff Report

Dialect: postgres

MetricValue
๐ŸŸข Tables Added1
๐Ÿ”ด Tables Removed0
๐ŸŸก Tables Modified1
โš ๏ธ Breaking Changes0
๐Ÿ“Š Risk Score15/100 (Low)

Generated Migration

CREATE TABLE posts (
  id SERIAL PRIMARY KEY,
  user_id INTEGER NOT NULL,
  title VARCHAR(255) NOT NULL,
  body TEXT,
  created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

ALTER TABLE users ADD COLUMN bio TEXT;

Generated by the SchemaLens GitHub App. Add Slack/Teams alerts and a team dashboard with SchemaLens Team.

Optional repo config

Create .schemalens.json in your repo root to override auto-detection. Without it, the app diffs the only changed .sql file, or asks for a config when multiple SQL files change.

// .schemalens.json { "schemaPath": "schema.sql", "dialect": "postgres" }

Permissions the app requests

PermissionAccessWhy
ContentsReadRead schema SQL files from the repo.
Pull requestsRead & WriteRead changed files and post/update PR comments.
MetadataReadRequired by GitHub for all apps.

GitHub App vs GitHub Action

Both give you schema diff reports in pull requests. Choose the one that fits your workflow.

FeatureGitHub AppGitHub Action
No workflow file or YAMLโœ“โ€”
Auto-detect changed .sql filesโœ“โœ“
PR comment with diff + migrationโœ“โœ“
Breaking change gateโœ“โœ“
Job summary / check run outputโ€”โœ“
Slack/Teams drift alerts (Team)โœ“โœ“
Best forTeams who want zero configTeams who want full CI control

Frequently asked questions

Do I need to change my CI/CD pipeline?

No. The GitHub App works entirely through GitHub webhooks and the GitHub API. You install it once and it comments on PRs automatically.

What SQL dialects are supported?

PostgreSQL, MySQL, SQLite, SQL Server, and Oracle. The app auto-detects the dialect from file content and path, or you can set it explicitly in .schemalens.json.

Is my schema data stored?

No. SchemaLens reads the SQL file, computes the diff in memory, posts the comment, and discards the data. Nothing is logged or persisted on SchemaLens servers.

Can I use this with private repositories?

Yes. You choose which repositories the app can access during installation. It only reads the SQL files it needs to diff.

What happens when multiple SQL files change in one PR?

If only one .sql file changes, the app diffs it automatically. If multiple change, it looks for a .schemalens.json config to pick the schema file; otherwise it posts a comment asking you to add one.

Privacy note: SchemaLens reads the SQL file you point it to, computes the diff in memory, and posts a comment. No schema data is logged or persisted on SchemaLens servers.