---
title: "Add the TikTok Pixel to Joomla - Code Snippets"
description: "You're paying for TikTok Ads that send people to your Joomla site, and then the data stops. TikTok can tell you how many people clicked, but not how m"
url: "https://www.tassos.gr/docs/code-snippets/howto/analytics-tracking/tiktok-pixel"
date: "2026-08-24T00:57:39+00:00"
language: "en-GB"
---

[ Home ](https://www.tassos.gr/index.php?option=com_content&view=category&layout=blog&id=24&Itemid=1088) / [ Code Snippets ](https://www.tassos.gr/index.php?option=com_content&view=category&id=120) / [ How-to Guides ](https://www.tassos.gr/index.php?option=com_content&view=category&id=125) / [ Analytics &amp; Tracking ](https://www.tassos.gr/index.php?option=com_content&view=category&id=140)

#  Add the TikTok Pixel to Joomla

You're paying for TikTok Ads that send people to your Joomla site, and then the data stops. TikTok can tell you how many people clicked, but not how many bought, signed up, or came back.

Without that feedback the algorithm has nothing to optimize against, and your budget goes to the cheapest clicks instead of the best customers. The TikTok Pixel fixes that, and adding it to Joomla doesn't have to mean another plugin. You can add the TikTok Pixel to your Joomla site using Tassos Code Snippets.

## [What is the TikTok Pixel](#what-is-the-tiktok-pixel)

The TikTok Pixel is a small JavaScript tracker that reports website activity back to TikTok. It measures conversions from your ads, builds custom and retargeting audiences, and feeds TikTok the signals it uses to optimise campaign delivery.

## [How to get the TikTok Pixel](#how-to-get-the-tiktok-pixel)

You need a TikTok Ads Manager account.

1. Go to [TikTok Ads Manager](https://ads.tiktok.com/) and sign in.
2. Open **Tools → Events**.
3. Under **Web Events**, click **Manage** and then **Set Up Web Events**.
4. Choose **TikTok Pixel** and then **Manually install pixel code**.
5. Copy the pixel code, or note your **Pixel ID**, the string passed to `ttq.load()`.

## [How to Add the TikTok Pixel to Joomla](#how-to-add-the-tiktok-pixel-to-joomla)

1. Install **Tassos Code Snippets** if it isn't installed already.
2. Go to Joomla Administrator.
3. Open Components → Tassos Code Snippets.
4. Click **New**.
5. Give your snippet a descriptive title like "TikTok Pixel".
6. Select **HTML** snippet type.
7. Paste the following code, replacing **YOUR\_PIXEL\_ID** with your actual Pixel ID: ```
    <script>
    !function (w, d, t) {
      w.TiktokAnalyticsObject=t;var ttq=w[t]=w[t]||[];ttq.methods=["page","track","identify","instances","debug","on","off","once","ready","alias","group","enableCookie","disableCookie"],ttq.setAndDefer=function(t,e){t[e]=function(){t.push([e].concat(Array.prototype.slice.call(arguments,0)))}};for(var i=0;i<ttq.methods.length;i++)ttq.setAndDefer(ttq,ttq.methods[i]);ttq.instance=function(t){for(var e=ttq._i[t]||[],n=0;n<ttq.methods.length;n++)ttq.setAndDefer(e,ttq.methods[n]);return e},ttq.load=function(e,n){var i="https://analytics.tiktok.com/i18n/pixel/events.js";ttq._i=ttq._i||{},ttq._i[e]=[],ttq._i[e]._u=i,ttq._t=ttq._t||{},ttq._t[e]=+new Date,ttq._o=ttq._o||{},ttq._o[e]=n||{};var o=document.createElement("script");o.type="text/javascript",o.async=!0,o.src=i+"?sdkid="+e+"&lib="+t;var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(o,a)};

      ttq.load('YOUR_PIXEL_ID');
      ttq.page();
    }(window, document, 'ttq');
    </script>
    ```
8. Select **Site Header** as the "Insertion Method".
9. Publish the snippet.
10. Optionally, open the **Conditional Logic** tab to restrict which pages the snippet runs on. Leave it empty to run it site-wide. Learn more in [Using Conditional Logic](https://www.tassos.gr/docs/code-snippets/functionality/conditional-logic).

Congrats! You've successfully added the TikTok Pixel to your Joomla site without installing another plugin.

## [Track a Conversion Event](#track-a-conversion-event)

The base pixel reports page views. To report a specific action, such as a purchase or a form submission, add a second snippet that fires only on that page.

1. Create a new snippet and select **JS** as the snippet type.
2. Paste the event code, adjusting the values to your own: ```
    ttq.track('CompletePayment', {
        value: 99.99,
        currency: 'EUR'
    });
    ```
3. Select **Site Footer** as the "Insertion Method" so the event fires after the base pixel has loaded.
4. Open the **Conditional Logic** tab and limit the snippet to your order confirmation page. This step matters: without it, the event fires on every page.
5. Publish the snippet.

TikTok optimizes best for its standard event names, such as `CompletePayment`, `AddToCart`, `ViewContent`, `SubmitForm`, `Contact`, and `CompleteRegistration`. Use the same pattern for each one.

## [Verify it Works](#verify-it-works)

Install the [TikTok Pixel Helper](https://chromewebstore.google.com/detail/tiktok-pixel-helper/aelgobmabdmlfmiblddjfnjodalhidnn) extension for Chrome, then visit your site. The extension shows the pixel firing and lists the events it picked up.

You can also open **Tools → Events → Test Event** in TikTok Ads Manager and browse your site to watch events arrive in real time. If nothing shows up, confirm the snippet is published and set to `Site Header`, check the Pixel ID, and disable any ad blocker in your test browser.

For more information about snippet types and insertion methods, visit our documentation: <https://www.tassos.gr/docs/tassos-code-snippets/>

 Last updated on Aug 14th 2026 15:08
