# Final Deployment Cost Estimates

## Real-Time vs Realistic Estimates

### ⚠️ Important Note

**Current gas prices (~0.07-0.09 gwei) are EXTREMELY LOW and not representative of normal market conditions.**

For **budgeting and planning**, use the **realistic estimates** (30-50 gwei) rather than current ultra-low prices.

## Real-Time Estimates (Current Market)

**Last Updated**: $(date -u +"%Y-%m-%d %H:%M:%S UTC")

Run `./scripts/deployment/calculate-accurate-costs.sh` for the latest real-time estimate.

### Current Gas Price: ~0.08 gwei

| Item | Gas | Cost (ETH) | Cost (USD) |
|------|-----|------------|------------|
| CCIPWETH9Bridge | 263,000 | ~0.00002 ETH | ~$0.05 |
| CCIPWETH10Bridge | 263,000 | ~0.00002 ETH | ~$0.05 |
| Configuration | 200,000 | ~0.00001 ETH | ~$0.04 |
| **Total** | **726,000** | **~0.00006 ETH** | **~$0.15** |

> **Note**: This is based on current ultra-low gas prices. **Do not use for budgeting.**

## Realistic Estimates (Normal Market Conditions)

### At 30 gwei (Low Activity - Recommended for Budgeting)

| Item | Gas | Cost (ETH) | Cost (USD @ $2,500/ETH) |
|------|-----|------------|-------------------------|
| CCIPWETH9Bridge | 263,000 | ~0.00789 ETH | ~$19.73 |
| CCIPWETH10Bridge | 263,000 | ~0.00789 ETH | ~$19.73 |
| Configuration | 200,000 | ~0.006 ETH | ~$15.00 |
| **Total** | **726,000** | **~0.02178 ETH** | **~\$54.46** |

**Recommended Budget**: **0.05 ETH (~$125)** with buffer

### At 50 gwei (Moderate Activity)

| Item | Gas | Cost (ETH) | Cost (USD @ $2,500/ETH) |
|------|-----|------------|-------------------------|
| CCIPWETH9Bridge | 263,000 | ~0.01315 ETH | ~$32.88 |
| CCIPWETH10Bridge | 263,000 | ~0.01315 ETH | ~$32.88 |
| Configuration | 200,000 | ~0.01 ETH | ~$25.00 |
| **Total** | **726,000** | **~0.0363 ETH** | **~\$90.75** |

**Recommended Budget**: **0.075 ETH (~$188)** with buffer

### At 100 gwei (High Activity)

| Item | Gas | Cost (ETH) | Cost (USD @ $2,500/ETH) |
|------|-----|------------|-------------------------|
| CCIPWETH9Bridge | 263,000 | ~0.0263 ETH | ~$65.75 |
| CCIPWETH10Bridge | 263,000 | ~0.0263 ETH | ~$65.75 |
| Configuration | 200,000 | ~0.02 ETH | ~$50.00 |
| **Total** | **726,000** | **~0.0726 ETH** | **~\$181.50** |

**Recommended Budget**: **0.15 ETH (~$375)** with buffer

## Budget Recommendation

**For Mainnet Deployment**: **0.05 ETH (~$125)**

This provides:
- Sufficient funds for deployment at 30 gwei
- Buffer for gas price spikes
- Configuration costs
- Safety margin

## Real-Time Gas Price Sources

The system uses the following sources (configured in `.env`):

1. **ETHEREUM_MAINNET_RPC** - Infura Mainnet endpoint (primary)
2. **INFURA_GAS_API** - Infura Gas API (fallback)
3. **Default RPC** - Public endpoint (final fallback)

## Getting Latest Estimates

```bash
# Get current gas price
./scripts/deployment/get-accurate-gas-price.sh

# Calculate accurate costs
./scripts/deployment/calculate-accurate-costs.sh

# Update all documentation
./scripts/deployment/finalize-cost-estimates.sh
```

## Summary

- **Current Real-Time**: ~0.00006 ETH (~$0.15) at ~0.08 gwei ⚠️ Ultra-low
- **Realistic Budget**: **0.05 ETH (~$125)** at 30 gwei ✅ Recommended
- **High Activity**: 0.15 ETH (~$375) at 100 gwei

**Always check gas prices before deployment and budget for normal conditions (30-50 gwei).**
