
URL Shortener
A backend-focused application for shortening URLs with secure authentication and authorization using JWT and bcrypt. Includes a well-structured MongoDB schema and multiple RESTful API endpoints built with a modular Node.js architecture.
Project Documentation
š URL Shortener & Analytics Platform
URL Shortener & Analytics is a full-stack web application that allows users to convert long URLs into short, easy-to-share links while tracking detailed analytics about their links.
It provides an efficient way to create, manage, share, and monitor shortened URLs from a single platform.
š” Problem Statement
Long URLs can be difficult to share, remember, and manage. Additionally, users often do not know how their shared links are performing, such as how many people clicked them.
URL Shortener & Analytics solves this problem by converting long URLs into short links and providing analytics to help users monitor link performance.
⨠Key Features
- š Shorten Long URLs into simple and unique links
- ā” Fast Redirection to the original URL
- š² Unique Short Code Generation
- š URL Analytics and Click Tracking
- š Track Link Performance
- š Monitor Total Clicks
- š Easy Link Sharing and Copying
- š Secure User Authentication
- šļø Manage Created URLs
- š± Responsive User Interface
š Analytics
The platform provides analytics for shortened URLs, helping users understand how their links are being used.
Users can monitor:
- š Total number of clicks
- š Performance of individual shortened URLs
- š Link usage and engagement
- š Click activity over time
š ļø Tech Stack
Frontend
- React.js
- Tailwind CSS
- TanStack Query
Backend
- Node.js
- Express.js
Database
- MongoDB
āļø How It Works
- Users securely sign up or log in to the platform.
- Users enter a long URL they want to shorten.
- The application validates the original URL.
- A unique short code is generated.
- The original URL and short code are stored in the database.
- A shortened URL is generated and displayed to the user.
- When someone visits the shortened URL, they are redirected to the original destination.
- Each visit is tracked and stored for analytics.
- Users can view the performance and click analytics of their shortened URLs.
ā¶ļø Run Locally
Clone the Repository
git clone https://github.com/irfan-ansari303/url-shortner.git
cd url-shortner
Setup and Run Backend
cd backend
npm install
npm run dev
Setup and Run Frontend
Open a new terminal and run:
cd frontend
npm install
npm run dev
š Project Structure
url-shortner/
āāā frontend/ # React.js frontend application
āāā backend/ # Node.js and Express.js backend
āāā README.md
āāā .gitignore
šÆ Project Objective
The objective of URL Shortener & Analytics is to provide a simple and efficient platform where users can shorten long URLs and gain valuable insights into their link performance through analytics and click tracking.
š Shorten ⢠š¤ Share ⢠š Track ⢠š Analyze
šØāš» Author
Irfan Ansari Full Stack Developer
ā If you like this project, consider giving it a star!