> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cuprice.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Show or hide features based on what users paid for

Feature gating means controlling access to parts of your app based on what the user purchased. Cuprice makes this straightforward:

1. User pays via Stripe checkout
2. Stripe redirects to your success URL with a `session_id`
3. Your server calls the Cuprice Receipt API to get purchased features
4. You enable only those features in your app

## The flow

```
User pays → Stripe redirects → Your server verifies → Features unlocked
```

## What you need

* A server-side API route (to call the Receipt API securely)
* A way to store the user's subscription (database, localStorage for demos)
* Client-side UI that checks feature status

## Two types of purchases

<CardGroup cols={2}>
  <Card title="Regular Plans" icon="list" href="/feature-gating/regular-plans">
    User picks a pre-built plan like "Pro". You look up which features that plan includes.
  </Card>

  <Card title="Custom Plans" icon="puzzle-piece" href="/feature-gating/custom-plans">
    User picks individual features. The exact list comes from the receipt metadata.
  </Card>
</CardGroup>
