URL Shortener

High-performance URL shortening service built with Go

🎯 Live Demo


This demo shows how the URL shortener works with a real YouTube example:

📺 YouTube Example

Original URL:

https://www.youtube.com/watch?v=dQw4w9WgXcQ

Shortened URL:

https://url-shortener-bzrr.onrender.com/5AwY56

Try it:

🚀 Visit Short URL 📺 Original URL

⚡ Features

Fast Redirects

Sub-millisecond response times for instant URL redirection

Analytics

Track click counts and usage statistics for each shortened URL

Secure

Input validation and error handling for robust operation

RESTful API

Clean API endpoints for easy integration and automation

🛠️ Tech Stack

Go (Golang) Gin Framework RESTful API HTTP/HTTPS JSON In-Memory Storage

API Endpoints

Health Check:

GET /health

Create Short URL:

POST /shorten

Redirect to Original:

GET /:code

Get Analytics:

GET /analytics/:code