- ganaa7Asked on February 26, 2018 at 05:24 PM
Hi, Iam trying to add facebook pixel to my form. Is it possible to do that?
- JotForm SupportJanAnswered on February 26, 2018 at 07:58 PM
Unfortunately, it is not possible to insert the Facebook pixel code (script) on the form. According to Facebook guide, the pixel code should be inserted in the head element. There's currently no option in the Form Builder where you can insert a code in the head element.
You can also use the Thank You page to redirect to a custom URL where the Facebook pixel tracking code is. You just need to create a page, put the pixel on it, and then upload it to your web server. After that, you can redirect the Thank You page to that file.
My colleague Mike mentioned on this thread that it is possible to insert a Facebook pixel code using the noscript image tracking. You just need to get the tracking pixel image code that is located in between the tags. Here's an example:
<img height="1" width="1" style="display:none;" src="https://www.facebook.com/tr?id=1234567890&ev=PageView&noscript=1"/>
After that, you need to use the Text tool's Source Code and insert the image tracking code. Here's a screen capture:
Hope that helps. Thank you.