Next.js Discord

Discord Forum

Embedded widget / iframe

Unanswered
Portuguese Pointer posted this in #help-forum
Open in Discord
Portuguese PointerOP
I have a nextjs app hosted by vercel on a production URL, using mongodb as DB.
for example (www.myapp.com),

Can i provide my clients with a simple embed snippet they can use on their websites, which points directly to a page on my app?

For example:
<iframe src="https://www.myapp.com/some-specific-page?query=params" width="800" height="800"></iframe>

Is this approach feasible?

Any advice on which route to take for this super appreciated.

-------------------

Also taking into consideration
Could i handle security with some extra config in the embed for
X-Frame-Options

could this manage
sessions or login states
iframe-specific access control for sensitive pages

do i need to manage
browsers blocking third-party iframes

are the query params approach viable or should i go with unique, pre-signed URLs for each client to prevent tampering.
)

0 Replies