Skip to main content

What is the Embedded form campaign type?

Place an Alia form inside your page, such as your footer or a product page, instead of over it. Here's how embedded forms work and how to add one.

Written by Rob D

When you create a campaign in Alia, you choose one of three campaign types: Standard, Embedded form, or Subscription upsell. The type you choose determines what the popups in that campaign can do. Learn more: What is a campaign type?

How embedded forms work

Every popup you create in this campaign type is automatically placed within your page, so there's no need to set this up for each one individually. You can still customize each popup as usual, including its design, targeting, and suppression rules.

Embedded forms collect email and SMS signups the same way as standard Alia popups, with the same bot protection. The only difference is where they appear.

Triggers don't apply to embedded forms. The form shows as soon as a visitor who matches your targeting loads a page that has the embed snippet.

Customization options for embedded forms

You can customize your embedded forms to better suit your needs and branding. Here are some options:

  • Combine email and phone collection: collect both email and phone information in a single step for a streamlined experience.

  • Adjust form size and fonts: reduce the overall size and header font to create a more compact layout.

  • Remove images and logos: opt for a cleaner design by excluding images and logos.

  • Include legal text: add SMS legal text directly within the form to ensure compliance.

Creating your Embedded form campaign

  1. Create a new campaign and select Embedded form as the campaign type.

  2. From there, create and design your popup as usual.

  3. Once your popup is ready, you'll use its embed snippet to tell your website where the form should appear. You'll find the snippet under the Embed tab in the popup editor's right panel.

    The embed snippet in the Embed tab

Adding your embedded form to Shopify

For most Shopify themes, the easiest way to add your Alia form is with a Custom Liquid section.

💡 Note: Not on Shopify? Your site needs two things: the Alia base script, which loads Alia on every page, and the embed snippet, which marks where the form goes. See Adding an embedded form to a non-Shopify site. On Magento, Alia's module adds the base script for you. See Connecting your Magento store to Alia.

From your Shopify admin:

  1. Go to Online Store → Themes.

  2. Select Customize on the theme you want to edit.

  3. Navigate to the page or template where you want the form to appear.

  4. Add a Custom Liquid section.

  5. Paste the embed snippet provided by Alia into the Custom Liquid field.

  6. Move the section to where you'd like the form to appear.

  7. Save your changes.

Your Alia embed snippet will look similar to this:

<div id="__alia_mount_campaign_12345"></div>

Your campaign ID will be different. Think of this snippet as a placeholder: wherever you place the snippet is where Alia will display the embedded form.

Adding an embedded form to your footer

To display your form near the bottom of your storefront:

  1. Open the Footer area of your Shopify theme.

  2. Add a Custom Liquid section.

  3. Paste your Alia embed snippet into that section.

  4. Move the section to where you'd like the form to appear.

Your footer appears on most pages of your store, so a form you add there may show up throughout your storefront.

Adding an embedded form to a product or landing page

You can use the same process elsewhere on your storefront.

  1. Navigate to the appropriate product, page, or other template in the Shopify theme editor.

  2. Add a Custom Liquid section where you'd like the form to display.

If you only want the embedded form to appear on a specific page, make sure you are editing or creating the appropriate template for that page.

Adjusting the spacing around an embedded form

Depending on your Shopify theme and the size of your Alia form, you may find that the form sits too close to another section or overlaps the content above or below it. If this happens, adjust the padding in the Alia popup editor until you are satisfied with the result.

Using a custom selector

This option is best suited for users who are comfortable working with HTML and CSS selectors. If your website already contains an element where you'd like the form to appear, you can also use a custom selector instead of the standard embed container. Check Use a custom selector and enter a CSS selector for that element.

For example:

#newsletter-signup

or:

.footer-form

When you use a custom selector, Alia adds the form inside the first matching element on your page, after anything already in it. If no element matches, Alia looks for the standard embed snippet instead.

Previewing your embedded form before publishing

The Preview button in the popup editor shows how your form looks and behaves. However, it opens your form on a blank page, so it can't show you how the form fits into your storefront. To see your form in place on your own site before it goes live, add a preview key to the page's URL.

When previewing an embed campaign, it will initially appear as a popup. However, once embedded on your website, the form will adopt its true embedded appearance.

This is especially useful if you're replacing a form that's already on your site and want to check the new one before taking the old one down.

Previewing your form on your storefront

  1. Add the embed snippet to the page where you want the form to appear. For steps, see Adding your embedded form to Shopify in this article.

  2. In the popup editor, click Preview.

  3. In the tab that opens, copy the preview parameter from the end of the URL. It will look similar to this: ?alia_preview=XXXXXXXX

  4. Open the page where you added the snippet, and paste the preview parameter at the end of the page's URL. If the URL already contains a ?, replace the ? at the start of the parameter with &.

  5. Load the page. Your form appears where you placed the snippet.

💡 Note: Your form only appears when the page is opened with the preview parameter. Visitors to your store won't see it until you publish your campaign.

Previewing a replacement for a live form

If you'd rather not add anything to your live pages yet, you can preview your new form in one of these ways:

  • Use a copy of your theme. In your Shopify admin, go to Online Store → Themes, and duplicate your current theme. Add the embed snippet to the copy, select Preview on that theme, and add the preview parameter to the end of the preview URL. Your live store isn't affected.

  • Use a test page. Create a new page in Shopify that isn't linked from your store's navigation, add the embed snippet to it, and preview the form there.

  • Use a staging site. If your store has a staging or development site, add the embed snippet there and preview the form without affecting your live store.

  • Use a custom selector. If you're comfortable with HTML and CSS, you can point your new form at an element already on your page, such as the container your current form uses. For details, see Using a custom selector in this article.

💡 Note: If you use a custom selector that targets your current form's location, your new form will mount in that spot for all visitors once published. Make sure you remove or unpublish your old form at the same time.

Targeting and suppression rules

Embedded forms can still use Alia's targeting and suppression options.

For example, you can suppress an embedded form for visitors arriving from a particular traffic source using UTM parameters, just as you can with a standard popup. For more information, see Target popups by traffic source (UTM).

If you use the Viewed popup or Closed popup targeting conditions, here's how they apply to embedded forms:

  • Viewed popup: a visitor counts as having viewed your embedded form once they scroll to it. To leave your embedded form out of a Viewed popup condition, add Not in campaigns with that campaign.

  • Closed popup: moving through your embedded form's steps doesn't count as closing it.

How views are measured for embedded forms

Embedded forms record popup views, just like overlay popups. A view counts once at least half of the form is on screen, or the visitor taps or clicks into it. Each visitor counts once per popup. If your submit rate or popup view rate looks unusually high, see Embedded form best practices and troubleshooting.

Frequently asked questions

I added the embed snippet, but my form isn't showing. What should I check?

Start by opening your store in a private or incognito window, since targeting rules may hide the form from you if you've visited before. For the full checklist, see Embedded form best practices and troubleshooting.

Will visitors see both my embedded form and my overlay popup?

They can. Embedded forms and overlay popups are separate campaigns, and each follows its own targeting and suppression rules. If both campaigns' rules match a visitor, that visitor may see both. In some cases, an embedded form in the footer can sit alongside a welcome popup without feeling repetitive.

If you'd rather visitors see only one at a time, use targeting and suppression rules to control where each appears. For example, you could exclude your overlay popup from pages where your embedded form appears.

Can I have more than one embedded form on the same page?

Yes, as long as each form is its own Embedded form campaign. Each campaign shows its form once per page, so pasting the same snippet twice only shows one form. Create a separate campaign for each placement, such as one for a product description and one for your footer, and add each campaign's snippet where you want it.

What happens to the embedded form for visitors who have already subscribed?

After a visitor signs up, your embedded form shows its reward screen, welcoming them and confirming they're subscribed. When they return to your store, they'll continue to see this reward screen instead of the signup form, so existing subscribers aren't asked to sign up again.

You can customize the reward screen's message and button in the Alia popup editor to make the returning-visitor experience feel intentional, such as linking to a bestselling collection. Visitors who return on a different device or browser and have cleared their cookies may see the signup form again.

Can I convert my Embedded form campaign into a Standard campaign?

No. A campaign's type is set when you create it and can't be changed later. To show the same form as a popup, duplicate the campaign and choose Standard as the type for the copy. You can then show it with the usual popup triggers, or open it with the Alia SDK, for example, from a button click.

Still have questions?

Start a chat from inside the Alia app, or use the chat in our Help Center.

Did this answer your question?