# Aave Simple Earn Vaults

Aave Simple Earn Vaults are ERC-4626 compliant yield-bearing vaults that allow users to supply and withdraw ERC-20 tokens supported by Aave V3. Vaults manage the supply and withdrawal of assets in the Aave Protocol while enabling vault managers to take a fee on the yield earned.

To deploy a vault, follow the [deployment guide](./deploy).

Aave Simple Earn Vaults follow the [ERC-4626 Tokenized Vault Standard](https://eips.ethereum.org/EIPS/eip-4626), which standardizes the interface for yield-bearing vaults. This standard simplifies integration with various applications and aggregators while improving interoperability across the DeFi ecosystem.

Each vault allows depositors to:

- Deposit supported tokens (assets) and receive vault shares in return
- Redeem vault shares for the underlying assets plus accrued yield
- Automatically earn yield from Aave V3 markets without direct interaction with the protocol

## Architecture

Aave Simple Earn Vaults consist of three key components:

1. **ERC-4626 Interface**: Standardized methods for deposit, withdrawal, and accounting of assets.
2. **Yield Strategy**: Manages deposits into Aave V3 markets and handles yield accrual.
3. **Fee Management**: Enables vault managers to collect a percentage of the yield generated.

When a user deposits an asset into a vault:

- The vault mints proportional vault shares (ERC-20 tokens) to the user
- The vault deposits the underlying assets into the corresponding Aave V3 market
- The vault receives aTokens from Aave, which automatically accrue yield
- Yield is reflected in the increasing value of vault shares over time

## Fee Structure

> [!NOTE]
> Vaults deployed via Aave Labs’ API or SDK can set the performance fee as low
> as 0%. Aave Labs automatically receives 50% of any fee set.

Vault managers can set a fee percentage on the yield generated by the vault. This fee structure includes:

- **Performance Fee**: A percentage of the yield earned that goes to the vault manager
- **Max Fee**: A maximum limit on the performance fee that can be charged
- **Fee Recipients**: The addresses that receive the collected fees

Fees are collected when yield is realized through:

- User withdrawals or redemptions
- Explicit fee collection by the vault manager

The fee is only applied to the yield portion of the assets and not to the principal amount deposited by users.

## Interacting with Vaults

Vaults implement the standard ERC-4626 interface with methods such as:

- `deposit(uint256 assets, address receiver)`: Deposit assets and receive vault shares
- `withdraw(uint256 assets, address receiver, address owner)`: Withdraw assets by burning vault shares
- `mint(uint256 shares, address receiver)`: Mint exact amount of shares by depositing assets
- `redeem(uint256 shares, address receiver, address owner)`: Redeem shares for underlying assets

Additionally, vaults provide view functions to check:

- `totalAssets()`: Total assets managed by the vault
- `convertToShares(uint256 assets)`: Convert asset amount to vault shares
- `convertToAssets(uint256 shares)`: Convert vault shares to asset amount
- `previewDeposit(uint256 assets)`: Preview shares received for a deposit
- `previewWithdraw(uint256 assets)`: Preview shares needed for a withdrawal

For a detailed contract reference, see [the contracts documentation](/aave-v3/smart-contracts/vaults).

## Benefits for Users

- **Simplified Yield**: Earn yield from Aave V3 without managing multiple transactions
- **Standard Interface**: Easier integration with other DeFi protocols and applications
- **Composability**: Vault shares can be used in other DeFi applications

## Benefits for Vault Managers

- **Yield Capture**: Earn fees on yield generated by user deposits
- **Customization**: Configure fee parameters to suit different strategies
- **Standardization**: Leverage the ERC-4626 standard for broader integration
