> For the complete documentation index, see [llms.txt](https://docs.idle.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.idle.finance/other/guides/redeem-funds-smart-contracts.md).

# Redeem funds through smart contracts

This tutorial will guide you in the process of redeeming funds from Idle directly from the smart contracts in case the website has limited access or is down.&#x20;

### A. Redeem

1. Visit the vaults' addresses of [Best Yield](/developers/best-yield/deployed-contracts.md) and [Yield Tranches](/developers/yield-tranches/deployed-contracts.md) and select the one you want to redeem from. For YTs, you need to always use the contract tagged as *CDO*
2. Click on the *Contract* tab, and then on *Write as Proxy*
3. Click on *Connect to Web3* to connect your wallet
4. Select the function [`redeemIdleToken`](/developers/best-yield/methods/redeemidletoken-1.md) for BY or [`withdrawAA`](/developers/yield-tranches/methods/withdrawaa.md), [`withdrawBB`](/developers/yield-tranches/methods/withdrawbb.md) for YTs (where AA stands for Senior and BB for Junior)
5. Input the LP token amount you want to redeem unit converted. You can use [this tool](https://etherscan.io/unitconverter) to easily convert in multiple formats. Idle LP tokens have always 18 decimals (10^18).&#x20;
6. Click on *Write* and execute your Tx. If successful, you will see an outflow of the LP token selected and an inflow of the principal token.

<figure><img src="/files/F231NamvUsKcwHL8gk76" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The same process can be done through a multisig, i.e. a smart contract, by building the Tx using the *Transaction Builder* app. Safe fetches automatically the proper ABI of the contract.
{% endhint %}

Need further help? Check our [guides](/other/guides.md) list or get in contact on [Discord](https://discord.com/invite/mpySAJp).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.idle.finance/other/guides/redeem-funds-smart-contracts.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
