Help center / Identify customers, products and sales with query parameters

Identify customers, products and sales with query parameters

In some payment setups you will want to be able to identify data of a successful charge in your own system. You might want to save the payment to one of your users or save the products your customer paid for. The query parameter feature allows you to do so.

If you add query parameters when you link to your page, Checkout Page will 1. save these to the sale or subscription, 2. save these the payment or subscription in Stripe and 3. append these to the Redirect URL (if set).

These options allow you to keep track of information around the sale, to integrate with third party services via Stripe and Zapier and to save the data in your own system or to use it on a confirmation page.

Capturing query parameters

Let's walk through the scenario of identifying which of your users paid you through Checkout Page.

1. Find the best way to identify your users

In most applications or funnels, each user will have a unique identifier such as id, userId or email. This could also be a phone number, an oAuth token or session ID. Anything that's uniquely tied to a user works.

2. Add your query parameters to the URL of your page

Now copy the url of your Page, e.g.

When you link to this URL, you can add the identifier you found in step 1. Your query parameter could look like this: ?userId=101, userId being the name of the parameter and 101 being the identifier of your current user. If you want to add multiple query parameters, you can add them with a &, like ?userId=101&productId=110.

The full URL would now look like

Now, anytime a customer completes the checkout form, the query parameters and values will be saved to the sale or subscription and to Stripe.

Using query parameters

Captured query parameters are available in the Sale or Subscription in Checkout Page, in the Payment in Stripe and will be appended to the Redirect URL if you're using this. Let's see how you can access each of these.

1. Using query parameters in Checkout Page

You can find the captured query parameters in each Sale of Subscription item in Checkout Page. Simply go to your Sales or Subscriptions overview and click on the item you're looking for. You should then see the captured query parameters.

Query parameters in Sale

2. Using query parameters in Stripe and third party integrations

Checkout Page saves all your query parameters to the Payment or Subscription in Stripe. This allows you to keep track of your data in Stripe as well as use it with their webhooks and many third party integrations.

When saving query parameters to Stripe, the name of the parameter is prefixed with query_. That means that userId becomes query_userId. You can find the saved query parameters in each Payment or Subscription item in Stripe, in the Metadata section.

Query parameters in Stripe

3. Using query parameters with the Redirect URL

If you turn on the 'Redirect after payment' option, your customer will be redirected to your Redirect URL when a payment succeeds. If you used query parameters in the URL to your checkout page, we will append the parameters to your Redirect URL. With the past examples, this could look like Here you can extract those parameters using the technology of your choice and save details of the payment in your database.

Need more help?

Contact us via the Chat in the bottom-right corner or via email on