This is a simple URL shortener app built with Next.js and MongoDB. It allows users to shorten long URLs into short, manageable links that are easier to share. The app is live and can be accessed at next-shorten.vercel.app.
- Shorten long URLs into short, easy-to-remember links
- Customizable link aliases for personalized URLs
- Track the number of times a shortened link has been clicked
- View a list of previously shortened URLs with their respective analytics
- Delete shortened URLs if they are no longer needed
- Next.js: A React framework for building server-side rendered and static websites
- MongoDB: A NoSQL database for storing and retrieving URL data
- Vercel: A platform for deploying Next.js applications
To run the app locally, follow these steps:
-
Clone the repository:
git clone https://github.com/prodigytech/next_shortener.git
-
Navigate to the project directory:
cd next_shortener
-
Install the dependencies:
yarn install
-
Set up your MongoDB database and obtain the connection string.
-
Create a
.env
file in the root directory and add the following environment variables:MONGODB_URI=your-mongodb-connection-string
-
Start the development server:
yarn dev
-
Open your browser and visit http://localhost:3000 to access the app.
The app is deployed on Vercel and can be accessed at next-shorten.vercel.app. When deploying the app, make sure to set the MONGODB_URI
environment variable in your deployment settings to connect to your MongoDB database.