Documentation

Database Connection

Connect your project to an external database

Stellify requires an external database to store your application data. Connect to any MySQL or PostgreSQL database.

Overview

Your Stellify project needs a database connection to run migrations, store data, and test your application. Stellify doesn't host databases—you bring your own from providers like Supabase, PlanetScale, Neon, or your own server.

Database connection settings

Supported Databases

  • MySQL - Version 5.7 or higher
  • PostgreSQL - Version 12 or higher
  • MariaDB - Version 10.3 or higher

Connecting with Supabase

Supabase provides a free PostgreSQL database that works well with Stellify.

Supabase connection wizard

Quick Setup

  1. Create a free account at supabase.com
  2. Create a new project
  3. Go to Settings → Database in Supabase
  4. Copy your connection details
  5. Paste them into Stellify's database settings

Connection Details

From Supabase, you'll need:

  • Host: Your project's database host (e.g., db.xxxxx.supabase.co)
  • Port: 5432 (PostgreSQL default)
  • Database: postgres
  • Username: postgres
  • Password: Your database password

Other Providers

PlanetScale (MySQL)

  1. Create a database at planetscale.com
  2. Create a branch (or use main)
  3. Click Connect and select Laravel
  4. Copy the connection details to Stellify

Neon (PostgreSQL)

  1. Create a project at neon.tech
  2. Copy the connection string from your dashboard
  3. Enter the details in Stellify

Self-Hosted

If you're running your own database server:

  1. Ensure the database is accessible from the internet
  2. Create a database and user for your project
  3. Grant the user full permissions on the database
  4. Enter your server details in Stellify

Testing the Connection

After entering your credentials, click Test Connection to verify Stellify can reach your database.

If the connection fails, check:

  • Firewall rules: Ensure your database allows external connections
  • Credentials: Double-check username and password
  • SSL: Some providers require SSL connections
  • IP allowlist: Some providers require you to allowlist IP addresses

Running Migrations

Once connected, you can run migrations from Project Settings:

  1. Go to Project Settings → Database
  2. Click Run Migrations
  3. Stellify executes all pending migrations

You can also run migrations when creating models or using the resource scaffolder.


Next Steps