TimescaleDB schema diff — free to use

TimescaleDB Schema Diff.
Generate migrations.
Zero setup.

Paste two pg_dump --schema-only outputs from your TimescaleDB instances. Spot every hypertable, column, index, and constraint change instantly. Get ready-to-run ALTER TABLE scripts for TimescaleDB — all in your browser.

No account required. No data leaves your device.

Built for time-series workflows

SchemaLens understands TimescaleDB-specific syntax that generic diff tools miss.

⏱️

Hypertable Schema Comparison

Compares CREATE TABLE definitions for hypertables, including time-series columns, partition keys, and space dimensions.

📊

TIMESTAMPTZ & Time-Series Types

Correctly handles TIMESTAMPTZ, TIMESTAMP, INTERVAL, and custom time-series types across schema versions.

🔑

Indexes & Constraints

Primary keys, unique constraints, foreign keys, CHECK constraints, and time-optimized indexes — all compared semantically, not by raw text.

👁️

Continuous Aggregate Views

Detects changes in CREATE MATERIALIZED VIEW definitions for continuous aggregates, including column additions and filter modifications.

PostgreSQL-Native Parser

Because TimescaleDB is PostgreSQL under the hood, SchemaLens parses every hypertable, index, and constraint with full accuracy.

🔒

Privacy First

Your schema never leaves the browser. Compare production time-series schemas safely without uploading sensitive table structures to a third-party server.

How it works

1

Export your schemas

Run pg_dump --schema-only old_db > old.sql on both TimescaleDB databases.

2

Paste into SchemaLens

Copy the SQL into the two editor panes. Select PostgreSQL dialect — TimescaleDB is PostgreSQL-native.

3

Review the diff

See added hypertables, dropped columns, type changes, and constraint modifications highlighted in color.

4

Copy the migration

Export ALTER TABLE scripts, save as Markdown, PDF, or raw SQL. Run in staging, then production.

TimescaleDB migration examples

SchemaLens generates production-ready ALTER TABLE scripts for every change it detects.

Add a metric column to a hypertable

ALTER TABLE "metrics"
  ADD COLUMN "cpu_temp" DOUBLE PRECISION;

Change a column type

ALTER TABLE "events"
  ALTER COLUMN "metadata" TYPE JSONB;

Add a time-series index

CREATE INDEX "idx_metrics_device_time"
  ON "metrics" ("device_id", "time" DESC);

Add a foreign key

ALTER TABLE "sensor_readings"
  ADD CONSTRAINT "fk_sensor_device"
  FOREIGN KEY ("device_id") REFERENCES "devices"("id");

Related guides

Ready to diff your TimescaleDB schemas?

Join thousands of developers who use SchemaLens to catch schema changes before they hit production.

Start Comparing Free

Free for up to 10 tables. Pro starts at $12/mo.