Skip to main content

How Vault APY Is Calculated

Vault APY is a blended rate based on the reserves the vault’s capital is deployed across.
Vault APY ≈ Σ (Reserve APY × Allocation Weight)
Each reserve earns yield based on its utilization and borrow rate. A reserve at 80% utilization earning 8% APY contributes to the vault’s total yield based on its allocation weight, the share of capital deployed there. Allocation weights sum to 100% across all active reserves. Example — a USDC vault with two allocations:
ReserveAllocationAPY
USDC Main Market60%8%
USDC JLP Market40%12%
Blended APY = (60% × 8%) + (40% × 12%) = 9.6%
Underlying borrow rates and utilization levels change continuously, so vault APY fluctuates. Quoted APYs are trailing averages and are not guaranteed forward-looking rates. The displayed APY includes base interest from borrowers plus KMNO emissions when active. APY accounts for compounding. In Kamino vaults, earnings are continuously reinvested, increasing the vault share price over time.
1

Fetch All Vaults

Retrieve the list of all available vaults on Kamino.
const API_BASE_URL = 'https://api.kamino.finance';
const response = await fetch(`${API_BASE_URL}/kvaults/vaults`);
const vaults = await response.json();
The /kvaults/vaults endpoint returns all vaults with basic information including vault addresses, token mints, and strategies.
2

Get APY for Each Vault

Fetch APY metrics for all vaults in parallel using the vault public keys.
// Fetch all vault metrics in parallel
const vaultMetrics = await Promise.all(
  vaults.map(async (vault) => {
    const response = await fetch(
      `${API_BASE_URL}/kvaults/vaults/${vault.address}/metrics`
    );
    const metrics = await response.json();

    return {
      address: vault.address,
      apy7d: metrics.apy7d,
      apy30d: metrics.apy30d,
      apy90d: metrics.apy90d,
    };
  })
);

// Display all vault APYs
vaultMetrics.forEach((vault) => {
  console.log(`\n${vault.address}:`);
  console.log(`  7-day APY: ${(vault.apy7d * 100).toFixed(2)}%`);
  console.log(`  30-day APY: ${(vault.apy30d * 100).toFixed(2)}%`);
  console.log(`  90-day APY: ${(vault.apy90d * 100).toFixed(2)}%`);
});
The /kvaults/vaults/{pubkey}/metrics endpoint returns historical APY data across multiple timeframes (7-day, 24-hour, 30-day, 90-day, 180-day, 365-day).
You now have APY data for all vaults across multiple timeframes.

Lending Vaults Concepts

Learn how vaults work under the hood

Vault Data

Query vault metrics and positions

Benchmark Rate

Compare vault yields to market baseline

Earn Deposit

Deposit into vaults via API