NocoDB
Turn any database into a smart spreadsheet.
Overview
NocoDB is an open-source platform that transforms any database into a smart spreadsheet interface, providing an Airtable-like experience without vendor lock-in. Built with modern web technologies, NocoDB supports multiple database backends including PostgreSQL, MySQL, SQLite, and SQL Server, making it a versatile solution for teams who want spreadsheet simplicity with database power. The platform generates REST APIs automatically, offers real-time collaboration features, and provides advanced functionality like form views, gallery views, and kanban boards.
This Docker stack combines NocoDB with PostgreSQL to create a complete, self-hosted database management solution. PostgreSQL serves as the robust backend database engine, while NocoDB provides the intuitive web interface and API layer. This combination eliminates the need for complex database administration tools while maintaining full SQL capabilities underneath the user-friendly interface.
This setup is ideal for development teams, small businesses, and organizations seeking data sovereignty without sacrificing usability. Unlike cloud-based alternatives, this stack runs entirely on your infrastructure, giving you complete control over your data while providing the collaborative features modern teams expect. The PostgreSQL backend ensures enterprise-grade reliability and performance, while NocoDB's interface makes database interactions accessible to non-technical team members.
Key Features
- Visual database schema designer with drag-and-drop table creation and relationship management
- Multiple view types including grid, gallery, form, and kanban views for different data visualization needs
- Automatic REST API generation with authentication and role-based access control
- Real-time collaboration with user permissions, comments, and activity tracking
- PostgreSQL backend providing ACID compliance, full-text search, and advanced indexing capabilities
- Form builder for external data collection with customizable fields and validation rules
- Database import functionality supporting CSV, Excel, and direct database connections
- Webhook integrations and automation triggers for connecting with external services
Common Use Cases
- 1Customer relationship management (CRM) systems for small to medium businesses
- 2Project management and task tracking with team collaboration features
- 3Content management for blogs, documentation, and marketing materials
- 4Inventory management and product catalog administration
- 5Event planning and attendee management with form-based registration
- 6Data collection and survey management with public form interfaces
- 7Personal knowledge bases and information organization systems
Prerequisites
- Docker and Docker Compose installed on the host system
- Minimum 2GB RAM available for PostgreSQL and NocoDB containers
- Port 8080 available for NocoDB web interface access
- Basic understanding of environment variables for database password configuration
- Sufficient disk space for PostgreSQL data volume (recommend 10GB minimum)
- Network connectivity for initial container image downloads
For development & testing. Review security settings, change default credentials, and test thoroughly before production use. See Terms
docker-compose.yml
docker-compose.yml
1services: 2 nocodb: 3 image: nocodb/nocodb:latest4 container_name: nocodb5 restart: unless-stopped6 environment: 7 NC_DB: "pg://postgres:5432?u=nocodb&p=${DB_PASSWORD}&d=nocodb"8 ports: 9 - "8080:8080"10 depends_on: 11 - postgres12 networks: 13 - nocodb1415 postgres: 16 image: postgres:15-alpine17 container_name: nocodb-postgres18 restart: unless-stopped19 environment: 20 POSTGRES_USER: nocodb21 POSTGRES_PASSWORD: ${DB_PASSWORD}22 POSTGRES_DB: nocodb23 volumes: 24 - postgres_data:/var/lib/postgresql/data25 networks: 26 - nocodb2728volumes: 29 postgres_data: 3031networks: 32 nocodb: 33 driver: bridge.env Template
.env
1DB_PASSWORD=changemeUsage Notes
- 1Access at http://localhost:8080
- 2Airtable alternative
- 3Works with existing databases
Individual Services(2 services)
Copy individual services to mix and match with your existing compose files.
nocodb
nocodb:
image: nocodb/nocodb:latest
container_name: nocodb
restart: unless-stopped
environment:
NC_DB: pg://postgres:5432?u=nocodb&p=${DB_PASSWORD}&d=nocodb
ports:
- "8080:8080"
depends_on:
- postgres
networks:
- nocodb
postgres
postgres:
image: postgres:15-alpine
container_name: nocodb-postgres
restart: unless-stopped
environment:
POSTGRES_USER: nocodb
POSTGRES_PASSWORD: ${DB_PASSWORD}
POSTGRES_DB: nocodb
volumes:
- postgres_data:/var/lib/postgresql/data
networks:
- nocodb
Quick Start
terminal
1# 1. Create the compose file2cat > docker-compose.yml << 'EOF'3services:4 nocodb:5 image: nocodb/nocodb:latest6 container_name: nocodb7 restart: unless-stopped8 environment:9 NC_DB: "pg://postgres:5432?u=nocodb&p=${DB_PASSWORD}&d=nocodb"10 ports:11 - "8080:8080"12 depends_on:13 - postgres14 networks:15 - nocodb1617 postgres:18 image: postgres:15-alpine19 container_name: nocodb-postgres20 restart: unless-stopped21 environment:22 POSTGRES_USER: nocodb23 POSTGRES_PASSWORD: ${DB_PASSWORD}24 POSTGRES_DB: nocodb25 volumes:26 - postgres_data:/var/lib/postgresql/data27 networks:28 - nocodb2930volumes:31 postgres_data:3233networks:34 nocodb:35 driver: bridge36EOF3738# 2. Create the .env file39cat > .env << 'EOF'40DB_PASSWORD=changeme41EOF4243# 3. Start the services44docker compose up -d4546# 4. View logs47docker compose logs -fOne-Liner
Run this command to download and set up the recipe in one step:
terminal
1curl -fsSL https://docker.recipes/api/recipes/nocodb/run | bashTroubleshooting
- Database connection failed errors: Verify the DB_PASSWORD environment variable matches between NocoDB and PostgreSQL containers
- NocoDB container fails to start: Check if PostgreSQL container is fully initialized by examining logs with docker logs nocodb-postgres
- Permission denied on PostgreSQL data volume: Ensure the host directory has proper permissions or remove the volume to use Docker-managed storage
- Cannot access NocoDB interface: Verify port 8080 is not blocked by firewall and no other services are using this port
- Slow query performance: Monitor PostgreSQL memory usage and consider increasing shared_buffers in PostgreSQL configuration
- NocoDB shows blank page: Clear browser cache and check browser console for JavaScript errors, ensure containers can communicate on the nocodb network
Community Notes
Loading...
Loading notes...
Download Recipe Kit
Get all files in a ready-to-deploy package
Includes docker-compose.yml, .env template, README, and license
Ad Space
Shortcuts: C CopyF FavoriteD Download