A simple and efficient URL shortening service built with Next.js, Drizzle ORM, and PostgreSQL. The whole purpose of this project was to learn the basics of Next.js and Drizzle ORM while creating something useful.
- Shorten long URLs to easy-to-share links.
- Track click statistics for each shortened URL.
- Responsive design for both desktop and mobile users.
- Rate limiting to prevent abuse.
- Frontend: Next.js, React, Tailwind CSS
- Backend: Next.js API Routes, Drizzle ORM
- Database: PostgreSQL
- Caching: Redis (for rate limiting)
- Node.js (v18 or later)
- PostgreSQL database
- Upstash Redis account (for rate limiting)
- Clone the repository:
git clone https://github.com/d0dge-dev/shorter-url.git cd shorter-url
- Install dependencies:
npm install
- Set up environment variables:
cp .env.example .env
- Start the development server:
npm run dev
- Open your browser and navigate to
http://localhost:3000
.