Stripe
Attribute plan and above
Connect Stripe to see which campaigns and ads brought the people who paid you. Each payment, less any refund, is credited to the visits that led to it, by your attribution settings, and a buyer’s page in Visitors shows when they became a customer and what they paid.
Before you begin
- The Attribute plan.
- A Numbat role that can edit site settings. A Workspace Member cannot.
- Access to the Stripe account’s API keys. In Stripe that is usually an Administrator or a Developer.
- One Stripe connection per site.
Steps
You connect Stripe with a restricted key, a key that can only do what you allow. Numbat needs it to read six things.
-
Open the Stripe integration in Numbat Choose Open Stripe API keys. Stripe opens in a new tab. You can also open API keys in Stripe from here.
To try it out first, switch Stripe to test mode before you make the key. A test key reads only test data, and you can connect a live key later.

-
In Stripe, choose Create restricted key. When Stripe asks how the key will be used, choose Providing this key to a third-party application. Name it Numbat, with the URL numbat.io.

-
Tick Customize permissions for this key. Without the tick, Stripe gives the key its own default permissions.

Stripe turns some permissions on by default, so set every permission to None first. Each row has a None, Read and Write control.

Then set these six to Read, and leave everything else at None:
- Events
- Checkout Sessions
- Customers
- Subscriptions
- Invoices
- Charges and Refunds
The list is long, so use the search box to find each one by name, then set it to Read.

A few permissions sit inside a group, such as Billing for Subscriptions and Invoices. When the row itself is grayed out, set the group to Read and the ones inside it follow.

-
Choose Create key, then copy it. A live key starts with
rk_live_and a test key withrk_test_.
-
Back in Numbat, paste the key and choose Connect Stripe to
. Numbat checks that the key can read all six. If one is missing, the page names it, and nothing is saved. 
The card reads Importing with a running count of customers, then Syncing. Numbat imports the last 90 days of purchases first, then checks Stripe for new ones every few minutes.

What appears where
- Ad Campaigns shows Stripe revenue in the Revenue column, against each campaign, ad group, ad and keyword. Each currency shows on its own.
- Visitors gains a Revenue column, and a buyer’s page has a Stripe tab and Stripe rows on its timeline: started a trial, became a customer, paid and refunded.
How purchases are matched to visitors
A purchase only helps your reports once Numbat knows which visitor made it. Numbat tries two ways, in this order.
The first is the checkout link. When a visitor who allowed identification clicks a Stripe Payment Link on your site, or opens a Stripe pricing table, Numbat adds a reference to it. Stripe keeps that reference with the purchase, and Numbat reads it back. This needs nothing from you.
The second is email. If the buyer’s email is one Numbat has seen on your site, for example in a form they filled in, the purchase is matched to them.
If your own server creates the checkout
If your site sends visitors to a Stripe Checkout that your server creates, pass Numbat’s reference to it. In the page, ask Numbat for the reference and send it with the request that starts the checkout.
numbat("checkoutReference", function (reference) {
// reference is null when the visitor has not allowed identification
startCheckout({ numbatReference: reference });
});
On your server, set it as the Checkout Session’s client_reference_id. If
you already use client_reference_id for something else, keep your own
value there. Numbat leaves it alone and matches those purchases by email.
Check that it works
Once purchases have synced, the Stripe page shows how many of your Stripe customers were matched to a visitor, and how many by each route. Below it, the customers who did not match are counted by reason.
| Reason | What it means |
|---|---|
| Email not seen on your site | The buyer never gave Numbat that email. |
| No checkout link and no email | The checkout carried no reference, and Stripe has no email for the buyer. |
| Checkout opened over a day after the visit | The reference was too old by the time they paid. |
| Visitor not seen yet | The reference is valid, but Numbat had not recorded that visit when the purchase arrived. |
| Your own reference on the checkout | The checkout carried your own client_reference_id, so only email could match it. |
A low match rate is often normal. A buyer who paid without ever filling in a form, and without a checkout link from your site, can’t be matched.
If you also connect HubSpot
A sale can be both a won deal in HubSpot and a payment in Stripe, so Numbat never adds the two together. Ad Campaigns and Visitors show one of them. By default it is the one you connected first.
To change it, choose HubSpot won deals or Stripe payments under Revenue column on the Stripe page or the HubSpot page. Both pages show the same choice. You can change it at any time: nothing imported is lost, and the revenue shown changes the next time a page loads.

Disconnect Stripe
Disconnecting removes the key and everything Numbat imported from Stripe, including Stripe revenue in Ad Campaigns and Visitors. Nothing changes in Stripe. If you connect again, the import starts over.
- Open the Stripe integration in Numbat
- Choose Disconnect, then Disconnect Stripe to confirm.
- To revoke the key too, open Developers > API keys in Stripe and delete the Numbat key.
Troubleshooting
“This is a secret key”
You pasted a key that starts with sk_. A secret key can change your Stripe
account, so Numbat refuses it before it leaves the page. Make a restricted
key as in the steps above.
“This key cannot read …”
This key is missing one of the six permissions. Edit the key in Stripe, set the ones named to Read, and paste it again.
“This key reads the other Stripe mode”
The site is connected with a test key and you pasted a live one, or the reverse. Test and live purchases are never mixed. Disconnect first, then connect the new key.
The card says “New key needed”
Stripe no longer accepts the key, usually because it was deleted or expired. Syncing has paused, and everything already imported stays, including the revenue in Ad Campaigns. Paste a new restricted key on the Stripe page to resume.
Checked against Stripe Dashboard and API docs, November 2026.