Yes! You Can Host Your Own URL Shortening Service — and Even Build a Business on It!
How?
It’s easy! You can self-host it either locally or on the internet.
LibreShortURL
LibreShortURL is a minimalistic, privacy-friendly, and lightweight URL shortener.
Requirements
-
Server: Python
>= 3.13
, Linux (containerized or any distribution) - Domain: A short domain is recommended for better branding
Installation Process
- Clone the repository:
git clone https://github.com/junaidcodingmaster/LibreShortURL
cd LibreShortURL
- Build the app on the server:
chmod +x ./build-server.sh
./build-server.sh
-
Create a configuration file (
config.env
):
SERVER_DOMAIN="<YOUR DOMAIN WITH HTTP OR HTTPS>"
SERVER_HOST=0.0.0.0
SERVER_PORT=433
REQ_LIMIT_PER_DAY=50
- Deploy the app:
python app.py
If you encounter any errors, you can force start with Flask:
flask run --host "0.0.0.0" --port 433
Customization
To customize the UI, replace the following files with your own templates or design:
index.html
styles.css
index.js
These files are located in the /templates
folder.
Need Help?
- GitHub Repository: github.com/junaidcodingmaster/LibreShortURL
- Questions? Feel free to comment on the repository!
Stay curious and explore more.
~ Junaid
Author: Junaid
Top comments (0)