Embedding & Sharing a Quiz
Every published quiz gets a shareable link, plus a ready-made iframe snippet for embedding it directly on your own website.
Last updated
How do I embed my quiz on my website?
Open the quiz's menu and choose "Embed options", then copy the snippet. The Inline option is an iframe pointed at your quiz's share link with ?embed=true appended, plus one script line that sizes the frame to the quiz. Paste both into your site's HTML.
The embed snippet#
The Inline option under "Embed options" in the quiz menu gives you this exact snippet: an iframe with your quiz's share link and a ?embed=true query parameter that switches the page into an embed-friendly layout, followed by a small script that sizes the frame to the quiz:
<iframe src="https://fluotest.com/to/your-username/your-quiz?embed=true" width="100%" height="600" frameborder="0" style="border:none;border-radius:8px;" allow="clipboard-write"></iframe> <script src="https://fluotest.com/embed-resize.js" async></script>
Embed types: Popup, Slide-in, Exit-intent#
Beyond the plain inline iframe, the embed dialog can generate a single script tag instead. It loads embed-widget.js, which renders your quiz as a floating popup button, a slide-in panel from a corner, or a prompt that appears on exit-intent. Pick the mode in the embed dialog; the snippet below shows the Popup mode.
<script src="https://fluotest.com/embed-widget.js" data-quiz-url="https://fluotest.com/to/your-username/your-quiz" data-mode="popup" async></script>
data-mode accepts popup, slidein, or exit-intent. Optional attributes: data-button-text (popup/slide-in trigger label), data-color (accent color, defaults to FluoTest purple), data-position (bottom-right or bottom-left), and data-delay (slide-in delay in milliseconds, default 4000).
Height and width#
The frame takes the full width of the space you put it in. Its height follows the quiz: the small embed-resize.js script in the snippet makes the frame exactly as tall as the current step, so respondents never scroll inside it. When they move to the next step and the top of the quiz is out of view, it scrolls the page back to the top of the quiz. The height="600" attribute only applies until the script has loaded. It works for several quizzes on the same page. If your site has a sticky header, add data-fluotest-offset="80" (the header's height in pixels) to the iframe so the top of the quiz doesn't end up behind it.
Embeds copied before October 27, 2026 keep working at their fixed height. To get the automatic height, add this one line under the existing iframe:
<script src="https://fluotest.com/embed-resize.js" async></script>
Some website builders put custom HTML in a box of their own with a fixed height. No script on your page can change that box, so set its height in the builder's settings instead.
Badge removal and custom domains#
Free quizzes show a "Powered by FluoTest" badge on both the hosted page and the embed. Pro removes it. If you've connected a custom domain, check your domain settings for the exact link to use in place of fluotest.com.
Troubleshooting#
- The embed looks cut off or has a scrollbar: Check that the embed-resize.js script line sits under the iframe (embeds copied before October 27, 2026 don't have it) and that your site's Content-Security-Policy allows scripts from fluotest.com. If your website builder puts custom HTML in a fixed-height box of its own, raise that box's height in the builder.
- The quiz doesn't load in the iframe: Confirm the quiz is published, not soft-deleted, and that the share link works when opened directly in a new tab.
- The "Powered by FluoTest" badge still shows on Pro: Confirm the workspace is actually on Pro (or grandfathered): the badge is tied to the quiz owner's plan, not to the page it's embedded on.
- The popup, slide-in, or exit-intent quiz doesn't appear: Check that the script tag isn't blocked by a Content-Security-Policy that disallows third-party scripts or iframes, allow fluotest.com in your CSP. Exit-intent only fires once per browser session and only on desktop pointer movement, not on mobile.
Frequently asked questions#
Do I need any code beyond the iframe snippet to embed a quiz?
No. Paste the copied snippet (the iframe and the script line under it) into your site's HTML wherever you want the quiz to appear. The script only sizes the frame; without it the quiz still works at a fixed height of 600px.
Does the embedded quiz look different from the hosted version?
The ?embed=true parameter switches to a layout suited to being embedded (for example, without FluoTest's own page chrome around it), but the quiz content and behavior are the same.
Can I share the link directly instead of embedding it?
Yes, the same share link works as a standalone page. Use the plain link (without ?embed=true) for that.
What's the difference between the iframe snippet and the script snippet?
The iframe snippet renders the quiz inline, exactly where you paste it; its script line only sizes the frame. The script snippet (used for Popup, Slide-in, and Exit-intent) instead loads a small script that builds the trigger (a button, panel, or exit prompt) and only creates the iframe when the visitor engages with it.