Deliverability

Ontraport form blank in Wix Studio iframe: "Refused to connect"

A blank box or "Refused to connect" means the browser blocked the iframe because the framed page sends X-Frame-Options or a CSP frame-ancestors rule that excludes your Wix domain. Stop framing that URL. Use the form's script embed or lightbox script, or link to the hosted page.

Sohail HussainSohail Hussain9 min read

Short answer

  • The page your iframe points to sends a header (X-Frame-Options or a CSP frame-ancestors rule) that tells browsers not to show it inside other sites, so the browser shows "Refused to connect" or a blank box.
  • You can't change that from Wix. Replace the raw iframe with the form's script embed or lightbox script, or link to the hosted form page.
  • Confirm the cause first: open the published page, press F12, and look for an X-Frame-Options or frame-ancestors message in the Console.

You pasted an Ontraport form into a Wix Studio embed, and instead of the form you get a blank box or a gray error that says:

Refused to connect

Someone on r/WIX reported the same pattern: a CRM form that worked in Showit but failed in Wix Studio. I'm not linking the thread, and it doesn't say which embed method each builder was given. So treat the Showit/Wix difference as a likely explanation, not a proven one.

Why it happens

The message comes from the browser, not from Wix or from Ontraport's form logic. Before a browser draws a page inside an iframe, it reads that page's response headers. Two headers can forbid it.

X-Frame-Options: DENY
X-Frame-Options: SAMEORIGIN
Content-Security-Policy: frame-ancestors 'self'

DENY means the document can't be loaded in any frame, regardless of origin. SAMEORIGIN allows embedding only when every ancestor frame has the same origin as the page itself. Your Wix domain is a different origin, so both values block it. The frame-ancestors directive does the same job with finer control; when both are set, browsers that support frame-ancestors ignore X-Frame-Options. The idea is to stop clickjacking, where one page tricks users into clicking something on another.

What you see depends on the browser. The X-Frame-Options spec says some browsers show a message that lets the user open the page in a new window, while others simply render an empty frame. That is why one person sees "Refused to connect" and another sees nothing.

Only the site serving the page can change these headers. You can read the details in MDN's X-Frame-Options reference.

The usual causes, most common first:

CauseWhat you seeFix
Iframe points at a page that sends a frame-blocking header"Refused to connect" or a blank box; Console names X-Frame-Options or frame-ancestorsUse the script embed, the lightbox script or a link
Script embed pasted, but not renderingBlank area, no framing errorCheck for a blocked script, stripped code or an ad blocker
http:// form URL on an https:// Wix pageBlank box; Console reports mixed contentUse the https:// address
Wrong URL (admin or editor link)Login screen or error inside the frameCopy the public form link
Lightbox script present but trigger class missingButton does nothingAdd the exact class to the live button

Confirm the cause in two minutes

  1. Open the published Wix page in Chrome, not the editor preview. Use a private window so extensions don't interfere.
  2. Press F12 and open the Console tab, then reload.
  3. Look for a line that mentions X-Frame-Options or frame-ancestors, such as "Refused to display ... in a frame". That confirms a framing block.
  4. For the exact header, open the Network tab, reload, click the request for the framed document, and read Response Headers.

If the Console is clean and the box is still empty, skip to the blank-box section below.

Test the live page

The Wix editor and preview can behave differently from the published site. Always judge the fix on the live URL.

Fix 1: use the script embed instead of an iframe

An iframe asks the browser to load an entire Ontraport page inside your page, and that is the request being refused. A script embed asks Ontraport's code to build the form on your page, so you aren't framing a blocked page. I can't see your account, so I can't say which embed options your form offers.

  1. In Ontraport, open the form and look for its embed or code option. If the label has moved, search the form's settings for "embed".
  2. Copy the script version, not the link to the hosted form page and not an iframe snippet.
  3. In Wix Studio, add an HTML embed element from the Add panel (search for "embed" if the category name differs) and choose its code mode rather than the website-address mode.
  4. Paste the code, apply it, then publish.
  5. Test on the live URL.

Wix typically renders embedded code inside its own frame, so the form may still sit in an iframe on the Wix side. That frame is Wix's, not the blocked Ontraport page, which is why this route can work. If it still fails, check the Console for a blocked script or a content policy error.

Fix 2: use the lightbox script with a button class

If a pop-up suits the page, the lightbox embed opens the form when a visitor clicks an element carrying a specific CSS class. You place the script once and give your Wix button the class it expects.

  1. Copy the lightbox embed code from the form's embed options.
  2. Paste it into an HTML embed element on the page, then publish.
  3. Read the code and note the exact class or trigger it names.
  4. Add that class to your Wix button. If you can't find the field in Studio, search the Wix help for "add CSS class".
  5. Click the button on the live page.

I'd pick this over an inline form on mobile layouts, because the form doesn't fight your grid for space. The catch is that a missing class looks exactly like another blank failure: the click just does nothing.

If neither embed works, stop trying to make the form live inside the page.

  • Point a Wix button at the Ontraport-hosted form page. Nothing is framed, so no frame header applies.
  • Or serve the page from a subdomain you control, such as forms.example.com, and link to it. Visitors still see your brand in the address bar. Setting that up depends on your Ontraport account, so check Ontraport's help for custom domains.

This is the most reliable option. You lose the in-page feel, but it works in every browser and doesn't depend on any embed.

Don't chase a header workaround

Meta tags and Wix settings can't override a server header. MDN notes that X-Frame-Options is only enforced through HTTP headers, so a tag in the page won't change it either way.

If the box is blank but there is no frame error

  1. Mixed content. An http:// form URL inside an https:// Wix page gets blocked. Use the https:// address.
  2. Wrong URL. You may have copied an admin or editor link. Open it in a private window; if it asks you to log in, it's the wrong link.
  3. Ad blockers and privacy extensions. Reload with extensions off.
  4. Code stripped on save. Re-open the embed element after publishing and confirm the code is still there.
  5. Strict tracking protection. Some browser settings break third-party scripts. Try another browser.
  6. Wrong embed mode. Pasting script code into a website-address field (or the reverse) gives an empty box.

Checklist before you try again

  • The form is embedded as a script, a lightbox or a link, not as a raw iframe of the form page.
  • The URL starts with https:// and opens without a login.
  • The code is still present after you publish and reopen the element.
  • If you use the lightbox, the button has the exact trigger class.
  • You tested the published page in a private window with extensions off.
  • You tried a second browser.

If nothing works

Contact Ontraport support if the script embed fails on the published page and the Console shows a blocking error. If you specifically need framing, ask whether the form page can be framed from your Wix domain, because only they can change those headers. For a Wix-side problem, send Wix the same details. Include:

  • the form name and the published Wix URL
  • the exact error text and a screenshot of the Console message
  • your browser and version
  • which embed method you used and what you already tried
Subject: Form embed blocked on our Wix Studio site ("Refused to connect")

Hi, our Ontraport form "{form name}" does not display on {published Wix URL}.
In Chrome (version {x}) the frame shows "Refused to connect", and the Console reports:
{paste the X-Frame-Options or frame-ancestors message}.
We tried: {iframe / script embed / lightbox script}.
Can the form page be framed from our domain {your domain}, or which embed
method do you recommend for Wix Studio? Screenshots attached.

Common questions

Can I add my Wix domain to an allow list in Ontraport?

I can't confirm that Ontraport offers one for form pages. Ask support, as in the message above. Don't rely on the old ALLOW-FROM value: it is obsolete, and modern browsers ignore a header that uses it.

Why does the same form work in Showit?

I can't tell from the report which embed code each builder received. The likeliest difference is that one used a script and the other framed a page that forbids framing. Run the Console check on the failing page to find out.

Is it safe to work around the block with a proxy or a trick?

I'd skip it. The header exists to protect visitors from clickjacking, and proxying the page can break the form and its tracking. A script embed or a plain link solves the problem without that risk.

Will the form still add people to my list if the iframe is blank?

No. If the form never renders, nothing can be submitted. Once it works, submit a test entry and confirm it appears in Ontraport. If the form feeds an email list, our email deliverability checklist covers whether your welcome emails reach the inbox.

deliverabilityontraporterror-codes
Share this article
Sohail Hussain

Sohail Hussain

Founder & CEO at Mailneo

Building Mailneo — AI-powered email marketing for growing businesses.

Related Articles

Deliverability

0x800ccc0e: Outlook Unable to Connect to SMTP Server, Fixed

Outlook error 0x800ccc0e means the app could not open a connection to your outgoing (SMTP) server. Usually the port, encryption setting or password is wrong, or antivirus, a firewall or your ISP is blocking it. Set port 587 with STARTTLS, turn on SMTP authentication, and test again.

Sohail Hussain|10 min read
Deliverability

SocketLabs "421 4.5.1 Too many errors" blacklist: how to fix it

`421 4.5.1 Too many errors, you have been temporarily blacklisted` means a SocketLabs server saw repeated auth or bad-address errors from your IP and paused it. Stop whatever is retrying, fix credentials and invalid recipients, clear the queue, and wait. The block usually lifts within minutes, but returns if retries resume.

Sohail Hussain|9 min read
Deliverability

421-4.7.0 Gmail Has Detected This Message Is Suspicious: Fix

The 421-4.7.0 "suspicious due to the nature of the content and/or the links" error means Gmail's content filter rejected your message after DATA, not an authentication check. Remove click tracking or move it to your own domain, drop URL shorteners, check link reputation, then retest with a plain message.

Sohail Hussain|10 min read
Deliverability

421 4.7.0 IP not in whitelist for RCPT domain: what it means

The error 421 4.7.0 IP not in whitelist for RCPT domain means the recipient's mail gateway, usually Mimecast in reports, only accepts connections from approved IPs, and the Google sending IP isn't on that list. The fix is on the recipient side: their admin must allow the IPs or change the mail routing.

Sohail Hussain|9 min read

Ready to supercharge your email marketing?

Start sending smarter emails with AI-powered campaigns. No credit card required.

Get Started Free