> For the complete documentation index, see [llms.txt](https://support.emarketeer.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.emarketeer.com/docs/docs_se/referens/references/web-tracker/installing-the-web-tracker-script-on-your-website.md).

# Installera Web Tracker-skriptet på din webbplats

Installera eMarketeer Web Tracker på din webbplats så att du kan se vilka sidor dina kontakter besöker.

Den här guiden går igenom både den rekommenderade mallen för Google Tag Manager och en manuell installation. Du behöver inte vara teknisk — följ stegen i ordning. När du är klar, [installera även formulärets basskript på din webbplats](/docs/docs_se/guider/guides/forms/publish-a-form.md).

## Hämta ditt Tracker ID och skript

Innan du börjar behöver du ditt unika Tracker ID och skript.

1. Logga in på ditt eMarketeer-konto.
2. Klicka på kugghjulsikonen uppe till höger, välj **Account Settings**, öppna **Integrations** och klicka på **View scripts** under **Developer resources > Website Scripts**. Du måste vara administratör för att komma åt den här sidan.
3. Kopiera ditt tracker ID och, separat, formulärets basskript som visas längre ned på samma sida. Du behöver dem under installationen.

<div align="left" data-with-frame="true"><img src="https://2555292243-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FicfGEyRadiE4k7sV4O4o%2Fuploads%2Fgit-blob-f812811d475524f34fd8d3f15f45772c7fbd3639%2Finstalling-the-web-tracker-script-on-your-website-website-scripts-tracker-id.png?alt=media" alt="Panelen Website Scripts som visar tracker ID med kopieringsikonen"></div>

## Alternativ 1: Enkel installation (rekommenderas)

Använd detta alternativ om din webbplats kör Google Tag Manager (GTM) tillsammans med en samtyckesbanderoll för cookies.

Vi tillhandahåller en färdig mallfil som du kan importera direkt till GTM.

{% stepper %}
{% step %}

### Ladda ner mallfilen

{% file src="/files/mbUn6p3cSlgqhm6yrG0I" %}

Mallen är kompatibel med fler än tio av de vanligaste samtyckesplattformarna för cookies, inklusive CookieBot och CookieYes.
{% endstep %}

{% step %}

### Öppna Google Tag Manager

Logga in på [Google Tag Manager](https://tagmanager.google.com) och välj din webbplats container.
{% endstep %}

{% step %}

### Lägg till eMarketeer-taggmallen

1. I vänstermenyn, gå till Templates, sedan Tag Templates, sedan New.
2. Klicka på Import, välj `.tpl`-filen du laddade ner och klicka på Save.
   {% endstep %}

{% step %}

### Skapa taggen med mallen

1. Gå till Tags, sedan New.
2. Klicka på Tag Configuration och välj "eMarketeers Tracker Helper" (mallen du just lade till).
3. Ange ditt Tracker ID när du ombeds.
4. Godkänn eventuella efterfrågade behörigheter.
   {% endstep %}

{% step %}

### Publicera din container

Publicera din container i GTM.
{% endstep %}
{% endstepper %}

Trackern är nu igång och respekterar din samtyckesbanderoll.

## Alternativ 2: Manuell installation

Om du vill installera eMarketeers Web Tracker på något annat sätt, använd basskriptet nedan.

```html
<script type="application/javascript" src="https://app.emarketeer.com/public/scripts/t.js"></script>
<script>
   emtv2.init('YOUR TRACKER ID');
   emtv2.start(); //Only run when you get or already have consent.
   emtv2.stop(); //Run this if the visitor opts out.
</script>
```

Du kan implementera detta skript i vilket system som helst: en tag manager, din webbplats egna skript eller din samtyckesplattform. Kör det på varje sida du vill spåra.

Din uppgift är att anropa `start()` så snart du har samtycke. Om du inte har samtycke, anropa det inte. Om besökaren tidigare gav samtycke och sedan väljer bort spårning, anropa `stop()`.

## Behöver du hjälp?

Om du fastnar, kontakta oss på <support@emarketeer.com> så hjälper vi dig att slutföra installationen.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://support.emarketeer.com/docs/docs_se/referens/references/web-tracker/installing-the-web-tracker-script-on-your-website.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
