Create embed URL
Generate a temporary preview link to display your project inside another website without requiring visitors to log in. The link stays active for one hour and works only on your specified secure website address.
Teams on a Business plan or higher who want to embed a live preview of their project into an external dashboard, portal, or website.
Do this, in order
- 1
Create an API key in your workspace settings with the projects:write permission enabled.
The embed endpoint requires write-level access and Business plan authorization to generate embed links.
- 2
Send a POST request to https://api.lovable.dev/v1/projects/{project_id}/embed-url including your API key and the exact HTTPS website address where the app will be shown.
Lovable restricts the preview so it can only load on your approved website origin for security.
- 3
Insert the returned embed URL into an iframe tag on your website.
Visitors on that page can interact with the project preview immediately without needing a Lovable account.
Paste this into your project
Create an integration helper that calls the Lovable API endpoint POST /v1/projects/{project_id}/embed-url using our Lovable API key to retrieve an embed preview URL, and render that URL inside a full-height iframe container on the preview page.Words decoded
- iframe
- A window built into a webpage that loads and displays another webpage inside it.
- HTTPS origin
- The exact secure web domain (including https://) where your site is hosted.
- Scope
- The specific permission level assigned to an API key determining what actions it is allowed to perform.
Where people get stuck
- Embed URLs expire after exactly one hour, meaning your system must request a fresh URL whenever visitors need to view the preview.
- The embed will fail to load if the hosting page does not exactly match the HTTPS origin sent in the creation request.
- The generated URL displays the built project preview only, not the Lovable editor interface or the production published version.
- Calling this endpoint on plans lower than Business returns a payment required error.
The short version, steps, decoder and prompt on this page are written automatically from Lovable's own documentation and can lag or misread it. The official page is always the authority.