1
3 Comments

How to take stripe payment and register a new user?

Hey,

It’s my fist time integrating a payment provider (in this case stripe) and I’m wondering what the best flow is for taking payment and onboarding authorisation for new customers?

I want to if possible, be able to take payment before firebase auth credentials are made in the aim of increasing conversion and not losing a customer in between signing up and then paying..

So the way I’m thinking is that an unregistered user is on the pricing page, they hit buy, they go through the stripe payment flow, and once payment is complete, the checkout id (or whatever info is returned from stripe) is stored along with email address used, and on redirection back to my website after payment, the email is prepopulated on the signup page, and they can enter a password and sign up…. Just wondering if this is a. Possible and b. Good practice? Also I wonder how to handle the situation where an incorrect email is used in the stripe checkout process, as this would mean the users payment is now decoupled from their real email address..

on December 12, 2022
  1. 1

    Hello @Timdowd1984 👋

    Congratulations on working on your first product with Stripe 👏
    First of all, both approach our possible (creating users after payment or before) but the choice should be based on your product, i.e what are you selling ?

    If the payment requires an account (for example subscriptions on SaaS product), it's better to create the account beforehand so you can link the payment with the existing account.
    If if does not (for example, selling a one-off product), if you can avoid the user to create an account at all, you should do it, it will reduce friction. If you need account, you can then auto signup when you receive Stripe Checkout event (it would be better than just formatting a field client side).

    If you have more information on your product, I can give your more insight on what would be the best solution IMO 😊

    1. 1

      Hi thanks for the reply. In this case the payment will be for a saas subscription.. I've seen a few saas websites where they take payment before signing up a user - to me this feels like a good way to avoid some last second u turns on conversion?

      1. 1

        Hi 👋
        Well, IMO you're trying to solve an hypothetical conversion issue with a lot of complexity in your flow that seems unnecessary at your stage of the project.

        I'll answer the OP regardless but you should definitely stick with the common approach signup => pay and try to optimise conversion this way rather than trying to anticipate the other way around. Young startup product more often have an acquisition issue at first than a conversion one. To be clearer, get the word out, then try to optimise conversion, not the other way around.

        Assuming people do pay beforehand, it's unlikely they would enter a bad email on purpose. Why would they, if it cost money to do so? Based on that, most of your mismatch would be on typos.
        Unfortunately for you, there is no good way to solve the issue if they don't have an account link. You'll most likely receive support request to update email and have to verify account information by hand to make sure the user is whom he claims to be.

        The advantages of securing the user by making signup before are:

        • cost of reactivation/conversion is often lower than cost of acquisition
        • there is a lot of overhead trying to verify user if they don't have access to a secure authentication system we can link their payment with

        Hope this helps! 🙇

Trending on Indie Hackers
I shipped 3 features this weekend based entirely on community feedback. Here's what I built and why. User Avatar 155 comments I'm a lawyer who launched an AI contract tool on Product Hunt today — here's what building it as a non-technical founder actually felt like User Avatar 139 comments “This contract looked normal - but could cost millions” User Avatar 53 comments 👉 The most expensive contract mistakes don’t feel risky User Avatar 40 comments The indie maker's dilemma: 2 months in, 700 downloads, and I'm stuck User Avatar 32 comments I realized showing problems isn’t enough — so I built this User Avatar 32 comments