A universally unique identifier — a long random string used as a unique ID for database rows instead of simple numbers.
A UUID (Universally Unique Identifier) is a 128-bit identifier that looks like this: 550e8400-e29b-41d4-a716-446655440000. It's used as the primary key for rows in a database table.
You might wonder why not just use 1, 2, 3 as IDs. UUIDs solve several problems:
Supabase uses UUIDs everywhere. When you create a table, the id column is typically a UUID that auto-generates using gen_random_uuid(). The auth.users table also uses UUIDs, so when you create a foreign key like user_id, it references a UUID.
You rarely type UUIDs yourself. The database generates them automatically. You just reference them in queries and foreign keys:
CREATE TABLE notifications (
id UUID DEFAULT gen_random_uuid() PRIMARY KEY,
user_id UUID REFERENCES auth.users(id)
);
UUIDs are standard across SQL databases and are the default ID type in modern web development.
We give you the skills to build, deploy, and own a full product. Professional stack, AI co-pilot, no coding background required.