Skip to main content
Short answer: Create an event, choose With code, copy the JavaScript snippet on the page or action you want to track. Make sure the ShortPen Pixel is installed and the link has Enable Tracking Events turned on.
Don’t know what Code-Triggered events are? Learn more: Understanding Events and Conversions in ShortPen

Before you start

  • ShortPen Pixel installed on your site. Events require the Pixel.
  • Event tracking enabled on the link that will receive conversions. Conversions start only after the event exists.
  • Access to your site/app code (you’ll paste a small JS snippet).

How to trigger an event with code: Steps

1

Create the event

Go to Events → New Event, name it clearly (e.g., Signup), select With code, then Next.
2

Copy the snippet

In Trigger event by code, click Copy.
3

Paste it where the action happens

Place the snippet on the page(s) or in the handler that confirms the action (e.g., after a form submit or purchase confirmation).
4

Save the event

Click Save to finalize the configuration.
5

Test it (real-time)

Open the Event Testing Panel to confirm the event fires.

FAQ

URL-Triggered events fire when visitors land on a specific page (e.g., a thank-you URL). Code-triggered events fire via JavaScript when your app confirms an action. Both require the Pixel.