A no-nonsense URL shortener built with Go & React.
Follow these steps to set up the project for development or production.
LinkShort uses SQLite: No manual database installation required. The SQLite database file is created automatically on first run, and migrations are applied at startup.
You can run LinkShort with Docker or manually.
- Docker & Docker Compose
Check your environment:
# use the setup checker
make docker-setup-
Prepare environment variables
Copy and edit the configuration files:
# Backend config cp example.linkshort.yaml .linkshort.yaml # Edit .linkshort.yaml as needed # Frontend config cp web/env.example web/.env # Edit web/.env to match your environment
-
Build and start
make build-docker
-
Rebuild (if needed)
make re-build-docker
-
Stop
make down-docker
Notes:
- Ensure
.linkshort.yamlis in your working directory and mounted into the container - Database migrations run automatically on container startup
- Access the app at http://localhost:8000
-
Install dependencies
Requires Node.js and npm.
cd web npm install -
Configure environment
cp env.example .env # Edit .env as needed -
Development mode
npm run dev
Access at http://localhost:3001
-
Production build
npm run build
-
Prerequisites
Install Go 1.25+ and ensure it's in your PATH.
-
Configure
cp example.linkshort.yaml .linkshort.yaml # Edit .linkshort.yaml as needed -
Build
make build
-
Run
./linkshort --conf .linkshort.yaml
View all available commands:
make helpContributions are welcome! Feel free to open issues or submit pull requests.