How to use the raw code feature

If you’re looking for faster form load speeds, achieving max uptime, and having the ability to do some additional customizations outside of our Lead Form Builder, then this feature is for you.

Here's an example of a page using the Raw Code Feature: https://getleadforms.com/test-raw-code/

What’s the difference between the standard way of embedding a form and Raw Code?

When it comes to adding a LeadForm to your website, landing pages, and funnels you have two options.

Option 1: The Standard Way

First, let me assure you that there’s absolutely no problem with the standard way of adding a LeadForm to your website. In fact, this is still the recommended method for the majority of GetLeadForms users and requires a little less work on your side.

When you use the standard option, all that you really need to do is have the LeadForm script somewhere on your website and the form will work.

In this case, the form is more tightly bound to our servers, meaning that whenever you make a change to your form in the LeadForm Builder, GetLeadForms will automatically update your form on your website without you needing to re-embed a new snippet of code.

Since all of the form settings load directly from our servers, the form will usually take 1-2 seconds to load. This typically isn’t a big deal and seems to have little to no impact on conversions, however there are cases where some users need even faster load speeds and the ability to decouple the form’s settings from our servers.

Option 2: Using Raw Code

The raw code option is very similar to the option above, however you’ll get an additional block of code to add to your website.

This block of code loads almost all of the HTML, CSS, and Javascript on your website, while only having the form connecting to just a few key parts of our servers.

The benefit of using raw code is that you’ll have much faster load speeds (nearly instant) and you (or your dev team) can make changes directly to your form’s code without having to log into GetLeadForms to make changes — providing even more flexibility for customization.

The downside however, is that anytime you make a change to the LeadForm inside of the builder, you’ll need to re-generate a new block of raw code and re-embed the code into your site. However, this process shouldn’t take anymore than five minutes. If you care about speed and customization, then the trade-off will be worth it.

Watch this video to see how to use this feature:

Step by step instructions:

Step #1: Set Your Target URL(s)

After you finish building your form and you like the way it looks, go to “Add to Site” and add the target URL for any page where you’d like your form to appear.

Step #2: Add the GetLeadForms Pixel Script to your website/landing page:

It’s important to note that you’ll still need to add your GetLeadForms pixel script to your website in-order for the entire form to work.

Even though we de-coupled the majority of the form from our servers, there are still some parts of the form that remain tied to our servers. But don’t worry, it’s small stuff that won’t impact load speed.

Step #3: Using Raw Code with the Embedded form

Note: You can skip this step if you’re not using an Embedded form.

If you’re using the embedded form, then you’ll still need to include the embed code somewhere on the page. This line of code essentially dictates where the form is going to be located on the page, while the Raw Code dictates how the form will look and feel.

To find the Embed Code, simply scroll down to “Embed LeadForm” and copy the embed code.

Next, paste the embed code on your landing page — wherever you’d like the form to appear. In this case, we’re adding it to a landing page built within Unbounce.

Step #4: Generate Raw Code

Scroll down to Raw Code and click on the blue “Generate Raw Code” button.

Clicking “Generate Raw Code” will automatically create a block of code based on your most recent changes.

Important Note: Anytime that you make a change to your form, you will need to re-generate a new block of Raw Code.

Step #5: Add the Raw Code to Your Website or Landing Page

Finally, take the raw code and paste it somewhere into your website or landing page.

If you’re using WordPress, then I recommend pasting it below the section of the page.

You can also add the raw code directly to a code block in your page.

And that’s all there is to it!

Need help? Simply reach out to us and we'll get back to you as soon as possible.

Still need help? Contact Us Contact Us