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

# On-Demand GPU Quick Start

> Launch your first H100, H200, or B200 GPU instance

Use this guide to launch your first On-Demand GPU instance on Hyperbolic. This guide walks you through account setup, funding, SSH configuration, and launching your first GPU instance.

## Prerequisites

Before you begin, make sure you have:

<CardGroup cols={2}>
  <Card title="SSH Key Pair" icon="key">
    Required for secure instance access. We'll show you how to create one if needed.
  </Card>

  <Card title="Terminal Access" icon="terminal">
    Basic command line familiarity for SSH connections and running commands.
  </Card>
</CardGroup>

## Step 1: Create Your Account

<Steps>
  <Step title="Sign Up">
    Visit [app.hyperbolic.ai](https://app.hyperbolic.ai) and create your account using:

    * Email address
    * Google OAuth
    * GitHub OAuth
  </Step>

  <Step title="Verify Email">
    Check your inbox for a verification email and click the link to activate your account.
  </Step>
</Steps>

## Step 2: Generate & Add SSH Key

<Warning>
  SSH keys are required for instance access. Password authentication is disabled for security.
</Warning>

<Tabs>
  <Tab title="macOS/Linux">
    ### Generate a new SSH key

    ```bash theme={null}
    # Generate ED25519 key (recommended)
    ssh-keygen -t ed25519 -C "your-email@example.com"

    # Or generate RSA key (legacy)
    ssh-keygen -t rsa -b 4096 -C "your-email@example.com"
    ```

    ### Copy your public key

    ```bash theme={null}
    # For ED25519
    cat ~/.ssh/id_ed25519.pub

    # For RSA
    cat ~/.ssh/id_rsa.pub
    ```
  </Tab>

  <Tab title="Windows">
    ### Using PowerShell

    ```powershell theme={null}
    # Generate key
    ssh-keygen -t ed25519 -C "your-email@example.com"

    # Display public key
    type $env:USERPROFILE\.ssh\id_ed25519.pub
    ```

    ### Using PuTTYgen

    1. Download [PuTTYgen](https://www.putty.org/)
    2. Click "Generate" and move mouse randomly
    3. Save private key
    4. Copy public key from text area
  </Tab>
</Tabs>

### Add SSH Key to Hyperbolic

1. Go to [Account Settings](https://app.hyperbolic.ai/settings)
2. Navigate to "SSH Keys" section
3. Paste your public key
4. Click the "Save" button on bottom right

## Step 3: Fund Your Account

Add credits to rent GPUs.

<Tabs>
  <Tab title="Credit Card">
    1. Go to [Billing](https://app.hyperbolic.ai/billing)
    2. Click "Add Funds"
    3. Enter amount of credits you want to add
    4. Click "Pay Now"
    5. Complete payment via Stripe

    <Info>
      Credit card payments are processed instantly and securely via Stripe.
    </Info>
  </Tab>
</Tabs>

## Step 4: Choose Your GPU

Browse available GPUs and select based on your needs:

### GPU Selection Guide

For current rates, check live pricing in the [Hyperbolic console](https://app.hyperbolic.ai/gpus).

| Use Case                 | Recommended GPU   | Why                                        |
| ------------------------ | ----------------- | ------------------------------------------ |
| **Model Development**    | H100 80GB         | Industry standard for AI development       |
| **Production Training**  | H100 80GB         | Fast training, reliable performance        |
| **Large Models (70B+)**  | H200 141GB        | Maximum memory for huge models             |
| **Distributed Training** | H100 + InfiniBand | Multi-node clusters with fast interconnect |
| **Ultra-Large Models**   | H200 + InfiniBand | Next-gen performance for cutting-edge AI   |

<Card title="Browse On-Demand GPUs" icon="search" href="https://app.hyperbolic.ai/gpus">
  View real-time GPU availability and pricing
</Card>

## Step 5: Launch Your First Instance

### Quick Launch (Web UI)

<Steps>
  <Step title="Select GPU">
    1. Go to [Hyperbolic](https://app.hyperbolic.ai)
    2. Filter by GPU type, price, or region
    3. Click on an available GPU listing
  </Step>

  <Step title="Configure Instance">
    * **Storage**: Add if needed (optional)
    * **Label**: Name your instance (optional)
  </Step>

  <Step title="Launch">
    1. Review configuration and pricing
    2. Click "Start Building"
    3. Instance launches in less than 20 minutes
    4. Copy the SSH connection string
  </Step>
</Steps>

### Launch via API

Automate instance creation with our REST API:

<CodeGroup>
  ```bash Virtual Machine theme={null}
  curl -X POST "https://api.hyperbolic.xyz/v1/marketplace/virtual-machine" \
    -H "Authorization: Bearer $HYPERBOLIC_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "gpu_count": 1,
      "gpu_type": "H100"
    }'
  ```

  ```bash Bare Metal theme={null}
  curl -X POST "https://api.hyperbolic.xyz/v1/marketplace/bare-metal" \
    -H "Authorization: Bearer $HYPERBOLIC_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "gpu_count": 8,
      "gpu_type": "H100",
      "network_type": "infiniband"
    }'
  ```
</CodeGroup>

## Step 6: Connect to Your Instance

Once your instance is running, connect via SSH:

```bash theme={null}
# Basic connection
ssh ubuntu@<instance-ip>

# With specific key file
ssh -i ~/.ssh/id_ed25519 ubuntu@<instance-ip>
```

### First Commands to Run

```bash theme={null}
# Check GPU status
nvidia-smi

# Check CUDA version
nvcc --version

# Check available disk space
df -h

# Check Python and pip
python3 --version
pip3 --version

# Monitor GPU usage in real-time
watch -n 1 nvidia-smi
```

## Step 7: Start Building

### Quick Examples

<Tabs>
  <Tab title="Train a Model">
    ```python theme={null}
    # train.py
    import torch
    import torch.nn as nn
    from torch.utils.data import DataLoader

    # Check GPU availability
    device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
    print(f"Using device: {device}")

    # Your model
    model = YourModel().to(device)

    # Training loop
    for epoch in range(num_epochs):
        for batch in dataloader:
            inputs, labels = batch
            inputs, labels = inputs.to(device), labels.to(device)
            # Training code here
    ```

    Run with:

    ```bash theme={null}
    python3 train.py
    ```
  </Tab>

  <Tab title="Run Jupyter">
    ```bash theme={null}
    # Install Jupyter if not present
    pip install jupyter

    # Start Jupyter with no browser
    jupyter notebook --no-browser --port=8888

    # From your local machine, forward the port:
    # ssh -L 8888:localhost:8888 ubuntu@<instance-ip>
    # Then open: http://localhost:8888
    ```
  </Tab>

  <Tab title="Fine-tune LLM">
    ```bash theme={null}
    # Clone your repo or upload data
    git clone https://github.com/your-repo/llm-finetuning.git
    cd llm-finetuning

    # Install requirements
    pip install -r requirements.txt

    # Run fine-tuning
    python finetune.py \
      --model_name "meta-llama/Llama-2-7b-hf" \
      --dataset "your-dataset" \
      --output_dir "./fine-tuned-model"
    ```
  </Tab>
</Tabs>

## Managing Your Instance

### Monitor Usage

Check your instance status and billing:

```bash theme={null}
# On the instance - check GPU utilization
nvidia-smi

# Check running processes
ps aux | grep python

# Monitor system resources
htop
```

### Save Your Work

<Warning>
  Always save your work regularly to persistent storage or cloud backups!
</Warning>

```bash theme={null}
# Save to persistent storage
cp -r /workspace/results /mnt/storage/

# Upload to cloud storage
aws s3 cp model.pth s3://your-bucket/models/

# Push to git
git add .
git commit -m "Save checkpoint"
git push
```

### Stop or Terminate

<Tabs>
  <Tab title="Via Web UI">
    1. Go to [My Instances](https://app.hyperbolic.ai/instances)
    2. Find your running instance
    3. Click "Terminate"
  </Tab>

  <Tab title="Via API">
    ```bash theme={null}
    curl -X DELETE "https://api.hyperbolic.xyz/v1/marketplace/instance/<instance-id>" \
      -H "Authorization: Bearer $HYPERBOLIC_API_KEY"
    ```
  </Tab>
</Tabs>

## Common Issues & Solutions

<Info>
  If you're still experiencing issues after trying these solutions, please contact us at [**support@hyperbolic.ai**](mailto:support@hyperbolic.ai) or use the **Intercom chat widget** in the bottom-right corner for immediate assistance.
</Info>

### Connection Issues

<AccordionGroup>
  <Accordion title="Permission denied (publickey)">
    **Problem**: SSH key not recognized

    **Solution**:

    ```bash theme={null}
    # Check you're using the right key
    ssh -i ~/.ssh/correct_key ubuntu@<ip>

    # Verify key is added to account
    # Go to app.hyperbolic.ai/settings
    ```
  </Accordion>

  <Accordion title="Connection timeout">
    **Problem**: Cannot reach instance

    **Solution**:

    * Check instance is running in dashboard
    * Verify IP address is correct
    * Check firewall/security group settings
    * Try different region if persistent
  </Accordion>

  <Accordion title="Host key verification failed">
    **Problem**: SSH host key changed

    **Solution**:

    ```bash theme={null}
    # Remove old host key
    ssh-keygen -R <instance-ip>

    # Then reconnect
    ssh ubuntu@<instance-ip>
    ```
  </Accordion>
</AccordionGroup>

### GPU Issues

<AccordionGroup>
  <Accordion title="CUDA out of memory">
    **Problem**: GPU memory exhausted

    **Solution**:

    ```python theme={null}
    # Reduce batch size
    batch_size = 16  # Lower this

    # Use gradient accumulation
    accumulation_steps = 4

    # Clear cache
    torch.cuda.empty_cache()

    # Use mixed precision
    from torch.cuda.amp import autocast
    with autocast():
        output = model(input)
    ```
  </Accordion>

  <Accordion title="GPU not detected">
    **Problem**: nvidia-smi shows no GPUs

    **Solution**:

    ```bash theme={null}
    # Check drivers
    nvidia-smi
    ```

    GPU drivers are preinstalled on all instances. If `nvidia-smi` does not report your GPUs, contact support rather than installing drivers yourself.

    <Warning>
      Do not attempt to reboot the instance. Not all machines support rebooting, and a reboot may leave the instance unrecoverable.
    </Warning>
  </Accordion>
</AccordionGroup>

<Tip>
  **Still need help?** Our support team is available 24/7. Email [**support@hyperbolic.ai**](mailto:support@hyperbolic.ai) or click the chat widget for live assistance.
</Tip>

## Best Practices

<CardGroup cols={2}>
  <Card title="Optimize Usage" icon="dollar">
    Monitor GPU utilization to ensure you're getting the most from your H100/H200/B200 instances.
  </Card>

  <Card title="Save Checkpoints" icon="save">
    Regularly save model checkpoints and important data to persistent storage or cloud.
  </Card>

  <Card title="Monitor Usage" icon="chart-line">
    Use `nvidia-smi` and billing dashboard to track GPU utilization and costs.
  </Card>

  <Card title="Terminate When Done" icon="stop">
    Always terminate instances when finished to avoid unnecessary charges.
  </Card>
</CardGroup>

## Next Steps

<CardGroup>
  <Card title="Managing Instances" icon="server" href="/docs/on-demand/managing-instances">
    Learn advanced instance management, monitoring, and automation
  </Card>

  <Card title="Storage & Networking" icon="hard-drive" href="/docs/on-demand/storage-and-ports">
    Configure persistent storage and custom networking
  </Card>
</CardGroup>

## Need Help?

For additional support:

* **Email**: [support@hyperbolic.ai](mailto:support@hyperbolic.ai)
* **Live Chat**: Use the Intercom widget in the bottom-right corner
