Skip to content

Updating visuals

If you see any images containing outdated UI, please bear with us.

We are updating all content as quickly as possible to mirror our new UI.

Columns and relationships

Choose the right field types and constraints for your data.

Columns control what kind of data each record can store. You can also set constraints like required or unique, and create relationships to other records or users.

Column types

WeWeb supports multiple column types for storing different kinds of data:

Text

Freeform text strings for names, descriptions, notes, and any textual content.

Example uses:Names, email addresses, descriptions, notes, addresses

Number

Numeric values including integers and decimals.

Example uses:Prices, quantities, ages, counts, ratings

Date

Date and time values for timestamps and scheduling.

Example uses:Created dates, due dates, appointment times, updated timestamps

True/False

Boolean values for yes/no flags and toggles.

Example uses:isActive, isPublished, hasAccess, feature flags

JSON

Structured data in JSON format. Store complex objects and arrays.

Example uses:Configuration objects, metadata, API responses, nested data structures

UUID

Universally Unique Identifiers — random strings that guarantee uniqueness across systems.

Example uses:Record IDs, external system references, unique identifiers that need to work across databases

User

Links a row to a user from the Auth → Users system. Perfect for ownership and assignments.

Example uses:Created by, assigned to, owned by, last modified by

Link to Another Record

References a record in another table to create relationships.

Example uses:Order → Customer relationship, Task → Project relationship

Options and constraints

All column types support these common options:

Default Value

Auto-populate new records with a specified value when no value is provided. This ensures records always have sensible starting values.

Example: Set a default status of "draft" for new articles, or a default quantity of 1 for order items.

Value Must Be Unique

Prevents duplicate values across all records in the table. When enabled, attempting to insert or update a record with a duplicate value will fail.

Example uses: Email addresses, usernames, SKU codes, order numbers

Value Is Required

Rejects records with missing values. When enabled, you must provide a value when creating or updating records.

Example uses: Required fields like name, email, title, or any mandatory data

Description

Clarifies the column's purpose for your team and AI assistants. Good descriptions improve collaboration and make your data structure self-documenting.

Type‑specific settings

Some column types have additional configuration options:

Date Options

Has Time

Include a time component in addition to the calendar date. When disabled, only the date is stored. When enabled, you can store precise timestamps.

Use cases:

  • Disabled — Birth dates, publication dates, deadlines (date only)
  • Enabled — Created at, updated at, appointment times (date + time)

Default to Current Time

Auto-fill new records with the current date and time when created. Perfect for tracking when records are created or updated.

Example: Set created_at to default to the current time, so every new record automatically captures its creation timestamp.

User Options

Default to Current User

Set the value to the currently signed-in user when creating a record. Ideal for tracking ownership and authorship.

Example: Set created_by to default to the current user, so you always know who created each record.

Combine with other options:

  • Value must be unique — Ensure one row per user (useful for user settings or profiles)
  • Value is required — Prevent records without an owner

Linked Table

Choose which table this column links to. This creates a relationship between the two tables.

Example: Link an orders table to a customers table by creating a "Customer" column that links to the customers table.

Relationship patterns

Table relationships let you connect records across tables, so your app can work with related data instead of duplicating it. In practice, it means a record (like an order, a task, or a comment) can point to the record it belongs to (like a customer, a project, or a post), and you can then display, filter, and manage that connected data throughout your app.

View details from linked records

A Link to Another Record column stores the link between two records. If you want to show details from the linked record (not just its ID), use a View and enable the linked record’s fields in the view’s Columns panel.

Showing fields from a linked record →

Diagram showing how relationships connect records across tables

One-to-Many

One record in a table relates to many records in another table. Create this by adding a "Link to another record" column in the "many" table that points to the "one" table.

Example: One company has many leads

  • In the leads table, add a "Company" column that links to the companies table
  • Now each lead can reference one company, and each company can have multiple leads

User Ownership

Track which user owns or created a record using the User column type. You can then filter data to show only records owned by the current user.

Example: User-specific tasks

  1. Add an owned_by column of type User to your tasks table
  2. Set it to default to the current user
  3. Create a view with filter: owned_by = auth.user.id
  4. Now users only see their own tasks

Working with columns in API Endpoints

When creating or updating records through API Endpoints, values must match the column type:

Column TypeData FormatExample
TextString"John Doe"
NumberNumber42 or 19.99
DateISO 8601 string"2025-01-15T10:30:00Z"
True/FalseBooleantrue or false
JSONObject or Array{"key": "value"} or [1, 2, 3]
UUIDUUID string"550e8400-e29b-41d4-a716-446655440000"
UserUser ID string"user_abc123" or use auth.user.id
Link to Another RecordRecord ID string"rec_xyz789"

USING AUTH.USER.ID

When setting a User column from an API Endpoint, use auth.user.id to automatically reference the currently signed-in user. This is more secure than passing user IDs from the interface.

CONTINUE LEARNING

Create views of your data with filters, sorts, and parameters.

Views →