Stripe Checkout - pre-populate the email address

Hi there,

I have a multi-step signup flow.

  1. page URL: …myapp.com/signup…
    -Email and password inputs
    -sign the user up

  2. page URL: …myapp.com/signup?step=info…
    -collect more info
    -make changes to the current user
    -go to page: plan

  3. page URL: …myapp.com/plan…
    -on this page I have an embedded stripe HTML pricing table where the user can choose from different subscriptions

My question is:

When they press the subscribe button how can I pre-populate the current user’s email address on the following stripe checkout page?

When you run the API call to create a checkout session you can send in the parameter of customer email

Thanks for your reply. I understand what you’re saying. I probably didn’t detail my context enough.

So, in the multi-step signup flow, at the first step, I sign the user up, but he doesn’t have access to the app just yet.

In the second step, I collect more details about him, like his first name, last name, company name, etc. He still doesn’t have access to the app.

Then, at the third step, he lands on the plan page, where there is an HTML element that I pasted in (the pricing table’s code from Stripe). I don’t have control over the subscribe button because it’s an embedded code from Stripe.

At this point, the current user is logged in so I need his email address to be populated when he presses the subscribe button. Therefore the two email addresses will be the same in my database and in Stripe.

Is there a reason you can not just use the dynamic expression ‘current users email’ in the location you need the email address? Does the HTML code have a parameter to fill in for email? If it does you can use dynamic expressions in the HTML.

What is the HTML you are using?




From the code, doesn’t look like they give option to add email address. Maybe in their documentation they provide steps on how to add more to the code, but I don’t know. Never used this before.