design-schema

Generate Supabase database schemas with SQL migrations and RLS policies from natural descriptions.

1|Updated Oct 19, 2025
One-click install
npx skills add https://github.com/rdimascio/supabase-marketplace --skill design-schema
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: design-schema
Source: https://github.com/rdimascio/supabase-marketplace/tree/main/plugins/database-operations/.claude/skills/design-schema
Command: npx skills add https://github.com/rdimascio/supabase-marketplace --skill design-schema

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill designs comprehensive database schemas with normalized tables, relationships, constraints, and indexing strategies, including RLS considerations.

Core Features & Use Cases

  • Table Design: Create normalized tables with appropriate keys and constraints.
  • Relationships: Define one-to-many and many-to-many relationships with foreign keys.
  • Migration-Ready: Generate complete SQL migrations and include indexing.
  • Use Case: Design a blog schema with users, posts, and comments, including access policies.

Quick Start

Provide a complete SQL migration for a sample blog schema with users, posts, and comments, including RLS.

Frequently Asked Questions about design-schema

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I design a normalized database schema for my application?

Normalized database schemas organize data into related tables with primary and foreign keys to eliminate redundancy. This Skill translates your data requirements into production-ready schemas with proper relationships, constraints, and indexing strategies tailored to your entities and workflows.

Can I generate a complete SQL migration from data model requirements?

Yes. Provide your data entities and relationships, and this Skill generates complete DDL migration scripts with normalized tables, primary/foreign keys, NOT NULL and CHECK constraints, composite indexes, and one-to-many or many-to-many relationships via junction tables.

How do I set up Row Level Security policies alongside my database schema?

Row Level Security policies control data access at the row level in Supabase. This Skill generates RLS policies alongside your schema design, ensuring fine-grained access control is built into your migration from the start.

What indexing strategy should I use for database performance?

Indexing accelerates query performance on frequently accessed columns. This Skill designs indexing strategies including single-column and composite indexes based on your schema's access patterns and relationships.

Do I need to manually write constraints for my database tables?

No. This Skill automatically designs and includes NOT NULL, CHECK, primary key, and foreign key constraints in your schema based on your data requirements, ensuring data integrity without manual constraint coding.

Related Skills