> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vibehub.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Deploying Projects

> Ship your code to production with one click

## Overview

Once you've connected a deployment platform and configured your project, deploying is just one click away.

## Prerequisites

Before deploying, ensure:

1. You've [connected a platform](/deployment/overview) (Netlify or Vercel)
2. Your project is configured with a deployment target
3. You have owner access to the project

## Triggering a Deployment

<Steps>
  <Step title="Open Your Project">
    Navigate to the project you want to deploy
  </Step>

  <Step title="Click Deploy">
    Find and click the **Deploy** button
  </Step>

  <Step title="Monitor Progress">
    Watch the deployment status as it progresses through stages
  </Step>

  <Step title="View Your Site">
    Once complete, click the deployment URL to see your live site
  </Step>
</Steps>

## Deployment Stages

A typical deployment goes through these stages:

| Stage         | Description                            |
| ------------- | -------------------------------------- |
| **Queued**    | Deployment is waiting to start         |
| **Building**  | Running build commands (if configured) |
| **Deploying** | Uploading files to the platform        |
| **Ready**     | Deployment complete and live           |

<Note>
  Build times vary based on your project size and complexity. Most deployments complete within a few minutes.
</Note>

## Deployment Success

When a deployment succeeds, you'll see:

* **Green status indicator**
* **Live URL** to your deployed site
* **Timestamp** of completion

Click the URL to open your site in a new tab.

## Deployment Failure

If a deployment fails:

1. Check the error message in VibeHub
2. Review build logs in your platform dashboard (Netlify/Vercel)
3. Common issues:
   * Missing dependencies
   * Build command errors
   * Invalid configuration

### Debugging Failed Deployments

<AccordionGroup>
  <Accordion title="Build Command Failed" icon="hammer">
    Verify your build command is correct. Check that all dependencies are in package.json and the build works locally.
  </Accordion>

  <Accordion title="Missing Files" icon="file-circle-xmark">
    Ensure all required files are committed. Check .gitignore isn't excluding necessary files.
  </Accordion>

  <Accordion title="Environment Variables" icon="key">
    Some builds need environment variables. Configure these in your platform's dashboard.
  </Accordion>

  <Accordion title="Timeout" icon="clock">
    Very large builds may timeout. Consider optimizing your build process or splitting into smaller chunks.
  </Accordion>
</AccordionGroup>

## Deployment History

VibeHub tracks all your deployments:

| Field         | Description                     |
| ------------- | ------------------------------- |
| **Status**    | Success, failed, or in progress |
| **Platform**  | Netlify or Vercel               |
| **URL**       | Link to the deployed version    |
| **Commit**    | Which commit was deployed       |
| **Timestamp** | When it was deployed            |

### Viewing History

To see past deployments:

1. Open your project
2. Look for the deployment history section
3. Click any deployment to see details

## Deploying Specific Commits

Currently, VibeHub deploys the latest code on your selected branch. For deploying specific commits:

1. Switch to the branch containing the commit
2. Deploy from that branch

## Redeploying

To redeploy the same code:

1. Click **Deploy** again
2. A new deployment will start

This is useful for:

* Retrying after a transient failure
* Rebuilding with new environment variables
* Testing platform changes

## Best Practices

<AccordionGroup>
  <Accordion title="Test Locally First" icon="laptop">
    Run your build command locally before deploying to catch errors early.
  </Accordion>

  <Accordion title="Use Preview Deployments" icon="eye">
    Deploy feature branches to preview before merging to main.
  </Accordion>

  <Accordion title="Monitor Deploys" icon="chart-line">
    Keep an eye on deployment times. Increasing times may indicate build issues.
  </Accordion>

  <Accordion title="Check Platform Logs" icon="scroll">
    For detailed error information, always check your Netlify/Vercel dashboard.
  </Accordion>
</AccordionGroup>

## Deployment vs CI/CD

VibeHub deployment is manual and on-demand. For automatic deployments on every push, configure:

* **Netlify**: Connect your repo directly in Netlify settings
* **Vercel**: Connect your repo directly in Vercel settings

VibeHub deployment is great for:

* Quick manual deploys
* Deploying specific branches
* Testing before setting up full CI/CD

## Next Steps

<CardGroup cols={2}>
  <Card title="Configure Netlify" icon="n" href="/deployment/connecting-netlify">
    Fine-tune Netlify settings
  </Card>

  <Card title="Configure Vercel" icon="triangle" href="/deployment/connecting-vercel">
    Fine-tune Vercel settings
  </Card>
</CardGroup>
