Installation
Get started with Platforma by adding it to your Go project. This guide covers installation, prerequisites, and basic project setup.Prerequisites
Go 1.25+
Platforma requires Go version 1.25.0 or higher
PostgreSQL
PostgreSQL database for persistence (optional for basic usage)
Check Your Go Version
Verify you have the correct Go version installed:Install Platforma
Add Platforma to your project usinggo get:
- Download the Platforma module and its dependencies
- Update your
go.modfile with the required dependencies - Make all Platforma packages available for import
Dependencies
Platforma brings in several carefully selected dependencies:Platforma uses the lib/pq PostgreSQL driver, not pgx. If you’re migrating from another framework, you may need to adjust your database connection strings.
Create a New Project
Start a new Go project with Platforma:Basic Project Structure
Organize your Platforma application with this recommended structure:Minimal Setup
Create a minimalmain.go to verify your installation:
main.go
Database Setup (Optional)
If your application uses a database, set up PostgreSQL:Using Docker
Connection String Format
Platforma uses thelib/pq connection string format:
For production, always use
sslmode=require and never commit credentials to version control. Use environment variables or a secrets manager.Verify Installation
Check that all dependencies are correctly installed:Development Tools (Optional)
Platforma projects typically use Task for common operations:What’s Next?
1
Build Your First Server
Follow the Quickstart Guide to create a working HTTP server
2
Learn Core Concepts
Understand domains, services, and the application lifecycle
3
Explore Examples
Check out the demo-app in the Platforma repository
Troubleshooting
Go Version Too Old
If you see errors about Go version:Module Not Found
If imports fail:PostgreSQL Connection Issues
Verify your database is running and accessible:Ready to build?
Create your first Platforma HTTP server