Database Setup Guide
Complete guide to connecting your PostgreSQL database and obtaining the necessary credentials for Codeless Sync.
Database Setup Guide
This guide helps you connect your PostgreSQL database and obtain the necessary connection credentials for Codeless Sync (CLS).
CLS works with PostgreSQL databases including Supabase, Neon, and other PostgreSQL-compatible providers.
Prerequisites
- A PostgreSQL database (Supabase, Neon, or other provider)
- Your database should already be created in your provider's dashboard
- Access to your database connection credentials
Step 1: Access Your Database Provider
Navigate to your database provider's dashboard:
- Supabase: app.supabase.com
- Neon: console.neon.tech
- Other providers: Check your provider's documentation
If you're creating a new database, wait for the setup to complete before proceeding (usually takes 1-2 minutes).
Step 2: Find Your Connection String
Your connection string is typically found in your provider's dashboard under "Connection" or "Database Settings".
The connection string format is:
postgresql://username:password@host:port/database
For Supabase
- Go to Project Settings → Database
- Look for Connection string section
- Select URI format
- Copy the connection string (starts with
postgresql://)
For Neon
- Go to your project dashboard
- Click on Connection Details
- Copy the connection string (starts with
postgresql://orpostgres://)
For Other Providers
Look for:
- "Connection string", "Database URL", or "Connection URI"
- The string should start with
postgresql://orpostgres:// - Ensure it includes your password (may need to reveal or replace placeholder)
Your connection string contains your database password. Treat it like a sensitive credential and never expose it in client-side code or commit it to version control.
Step 3: Connection String Components
Understanding what's in your connection string:
postgresql://username:password@host:port/database
| Component | Description | Example |
|---|---|---|
username | Database user | postgres |
password | User password | your-password |
host | Database server address | db.abc123.supabase.co |
port | Connection port | 5432 or 6543 (pooler) |
database | Database name | postgres |
Step 4: Use in Codeless Sync
- Go to your CLS dashboard
- Navigate to Projects → New Project
- Enter a Project Name (e.g., "Production Database")
- Select your Database Platform (Supabase, Neon, or Other)
- Paste your Connection String from Step 2
- Click Test Connection to verify
- Click Create when validation succeeds
We recommend using a Transaction Pooler or Session Pooler connection string for better performance. Most providers offer pooled connections.
Security Best Practices
Keep Connection String Private
Your connection string should be treated like a database password:
- Store in environment variables
- Use secrets management (e.g., 1Password, AWS Secrets Manager)
- Restrict access to authorized team members only
- Never commit to Git repositories
- Never expose in client-side code
- Never share in public forums or screenshots
Rotate Credentials if Compromised
If you suspect your connection string has been exposed:
- Go to your database provider's dashboard
- Navigate to database settings or security
- Reset your database password
- Important: This will immediately invalidate the old connection string
- Copy the new connection string
- Update all CLS projects with the new credentials
Resetting your database password will immediately break all existing connections using the old credentials. Update CLS and any other services before resetting.
SSL Connections
CLS automatically applies SSL for secure connections. Your database provider must have SSL enabled (most providers enable this by default).
Testing Your Setup
After adding your database project to CLS:
- Create a test configuration
- Complete the table creation step (Step 4 in wizard)
- Run a manual sync
- Verify data appears in your database table
- Check sync history for any errors
Common Issues
Connection Failed
- Verify you copied the entire connection string
- Check for extra spaces at the beginning or end
- Ensure your database is active (not paused)
- Verify your internet connection
- Check that SSL is enabled on your database
Authentication Failed
- Confirm your password is correct in the connection string
- Check if the password was recently changed
- Ensure the password doesn't contain special characters that need URL encoding
- Try copying the connection string again from your provider
Connection Refused
- Verify the host and port are correct
- Check if your database provider requires IP allowlisting
- Ensure the database server is running
Database Not Found
- Verify the database name at the end of your connection string
- Check that you're connecting to the correct project
- Database names are case-sensitive
SSL/TLS Errors
- Verify SSL is enabled on your database
- Check your connection string SSL parameters
- Contact your database provider if issues persist
Connection Pooling
For better performance, use a connection pooler URL instead of a direct connection:
- Transaction Pooler: Best for serverless applications
- Session Pooler: Best for long-running connections
Check your database provider's documentation for pooler connection strings.
Next Steps
- Quick Start Guide - Create your first sync
- Projects - Learn about project management
- Configurations - Set up sync configs
- Troubleshooting - Common issues