Skip to content
All articles
Product5 March 2026·3 min read

How to add auth to your Lovable app

Shipping is the easy half.

Paycux engineering

Shipping is the easy half. The hard half is deciding what the thing is supposed to do for someone who has never read your roadmap and does not care about your architecture.

This piece walks through how we think about it at Paycux, what we have changed our minds about, and where the sharp edges are.

Prerequisites

Consider prerequisites. Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Step 1: Install the Next.js SDK

Consider step 1: install the next.js sdk. Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

  • Choose defaults as carefully as features
  • Settle the name before you ship the thing
  • Ship the smallest honest version
  • Say plainly what the feature does not do

Step 2: Configure your Paycux dashboard

Consider step 2: configure your paycux dashboard. Naming is design work. If the team argues about what to call something, the disagreement is usually about what it is, and shipping before that is settled means shipping the confusion to customers.

Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Step 3: Configure your environment variables

Step 3: Configure your environment variables deserves its own treatment. Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Defaults are the product.

Step 4: Wrap your app layout with AuthKitProvider

Consider step 4: wrap your app layout with authkitprovider. Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Step 5: Add the proxy

Consider step 5: add the proxy. Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Step 6: Create the login and callback routes

Consider step 6: create the login and callback routes. Defaults are the product. Most people will never open the settings screen, which means the behaviour you chose for them is the behaviour they will experience forever.

Ship the smallest version that is honest about its limits. A feature that does one thing completely beats one that does five things with an asterisk on each.

Where this leaves us

If there is one thing worth taking away, it is that the expensive decisions are the ones made implicitly. Making them on purpose costs an afternoon.

If you are working through the same problem and want to compare notes, the docs cover the mechanics and the console shows the behaviour on your own data.

Everything here, already built

Sign-in, enterprise SSO, directory provisioning, roles and an audit trail behind one API. Start with the quickstart and have a working sign-in this afternoon.

Start selling to enterprise customers

Create an account, point sign-in at Paycux, and get back to the part of the product that is actually yours.