> For the complete documentation index, see [llms.txt](https://docs.defx.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.defx.com/docs/trade/defx-perp-dex/insurance-fund.md).

# Insurance Fund

The insurance fund is a critical component of Defx, providing a safety net against losses in leveraged trading and protecting the DEX from potential bankruptcy during cascading liquidations. This fund is primarily financed through liquidation penalties.

In leveraged trading on Defx, each position has a defined liquidation price and a bankruptcy price. Should a position's market price fall to the liquidation price, the position is closed and liquidated. Any residual margin is typically allocated to the insurance fund and market-making vault.

Conversely, if the market price exceeds the bankruptcy price at liquidation, the resultant shortfall is compensated by the insurance fund.

Insurance Fund Address: 0xDD8Ac0c5105D97B3c093EEd2f1ecFa6467089d18<br>


---

# 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:

```
GET https://docs.defx.com/docs/trade/defx-perp-dex/insurance-fund.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
