# Referral Tracking

Referral Rocket provides robust tracking capabilities that allow you to monitor and analyze your referral program's performance in real-time. This guide will walk you through the different ways you can track referrals.

**Add Tracking script to the the pages where new users will land**

```
// Add this script in the HEAD tag
<script type="text/javascript" campaign-id="YOUR-CAMPAIGN-ID" defer src="https://app.referralrocket.io/widget/widgetIndex.js"></script>
```

1. [Automated referral tracking with Stripe](/docs/integrations/stripe/referral-tracking-with-stripe.md)
2. [Tracking referrals on signup](/docs/getting-started/campaigns/installing-tracking-your-referral-campaign/referral-tracking/track-referral-on-sign-up-page.md)
3. [Tracking referrals on payments](/docs/getting-started/campaigns/installing-tracking-your-referral-campaign/referral-tracking/track-referral-on-payments.md)

{% hint style="info" %}
Ensure that Referral Rocket script is added to any page that the new user would be taken to.&#x20;
{% endhint %}


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://referral-rocket.gitbook.io/docs/getting-started/campaigns/installing-tracking-your-referral-campaign/referral-tracking.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
