Skip to main content

Prerequisites

Before you begin, ensure you have the following installed and configured:
  • Node.js 20+ - Required for Next.js 15 and modern JavaScript features
  • npm, yarn, or pnpm - Package manager of your choice
  • Convex Account - Sign up at convex.dev
  • Clerk Account - Sign up at clerk.com
  • Resend Account (Optional) - For email notifications resend.com

Installation Steps

1

Clone the Repository

Clone the AiVault repository to your local machine:
git clone https://github.com/seyarhasir/AiVault2.git
cd AiVault2
2

Install Dependencies

Install all required packages using your preferred package manager:
npm install
This will install all dependencies including:
  • Next.js 15.4.9
  • React 19.2.1
  • Convex 1.32.0
  • Clerk Next.js 6.39.0
  • Tailwind CSS 4.1.11
  • And more…
3

Set Up Environment Variables

Create a .env.local file in the root directory:
cp .env.example .env.local
See the Environment Variables page for detailed configuration.
4

Initialize Convex

Set up your Convex backend:
npx convex dev
This will:
  • Create a new Convex project (if needed)
  • Set up database schemas
  • Start the Convex development server
  • Generate your NEXT_PUBLIC_CONVEX_URL
5

Configure Clerk Authentication

  1. Go to clerk.com and create a new application
  2. Copy your publishable key and secret key
  3. Add them to your .env.local file
  4. Configure sign-in and sign-up URLs (already set to /sign-in and /sign-up)
6

Start the Development Server

In a new terminal window, start the Next.js development server:
npm run dev
Your application will be available at http://localhost:3000

Verify Installation

Once both servers are running:
  1. Convex Dev Server should be running on port 3210 (or similar)
  2. Next.js Dev Server should be running on http://localhost:3000
  3. Navigate to http://localhost:3000 in your browser
  4. You should see the AiVault homepage

Common Issues

Port Already in Use

If port 3000 is already in use, you can specify a different port:
npm run dev -- -p 3001

Convex Connection Issues

Make sure your NEXT_PUBLIC_CONVEX_URL in .env.local matches the URL provided by convex dev.

Clerk Authentication Errors

Ensure your Clerk keys are correctly copied and that your application domain is configured in the Clerk dashboard.

Next Steps

Environment Variables

Configure all required environment variables

Configuration

Learn about Next.js and Tailwind configuration

Build docs developers (and LLMs) love