> ## Documentation Index
> Fetch the complete documentation index at: https://docs.manifestfinancial.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Embed in Web App

Connect can be easily embedded in your web application. Connect should be embedded in a scrollable `iframe`. We recommend a minimum size of 600px wide and 800px tall.

<Frame caption="Connect embedded in a popup-style iframe.">
  <img src="https://mintcdn.com/manifestfinancial/Zmfsb2exisBO0rx8/images/connect-web-embed.png?fit=max&auto=format&n=Zmfsb2exisBO0rx8&q=85&s=f8f9ebd673937b320147a9ca1003c87b" width="1942" height="1942" data-path="images/connect-web-embed.png" />
</Frame>

***

Connect will broadcast an event using `postMessage` with a body of `connect_exit` when you should close the modal. Here's an example listener:

```javascript theme={null}
function handleMessage(event) {
    if (event.data === "connect_exit") {
        // close modal here
    } 
}
window.addEventListener("message", handleMessage);
```
