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

# Payment Failed

> Your last subscription payment failed, so your account is on the Free plan until the payment goes through. Explanation of the error and how to fix it.

Your last subscription payment failed. While the payment is outstanding, your organization is on the Free plan limits. The API returns this error instead of [Limit Exceeded](https://docs.supadata.ai/errors/limit-exceeded.md) or [Upgrade Required](https://docs.supadata.ai/errors/upgrade-required.md) so that you can tell a billing problem apart from a plan limit.

```json theme={null}
{
  "error": "payment-failed",
  "message": "Payment Failed",
  "details": "Your last payment failed. Update your payment method to restore your plan.",
  "documentationUrl": "https://docs.supadata.ai/errors/payment-failed",
  "billingUrl": "https://dash.supadata.ai/organizations/<organization-id>/settings/organization/billing"
}
```

The HTTP status is `402`. `billingUrl` links to your organization's billing page in the dashboard.

## When it is returned

When a renewal payment fails, Stripe marks your subscription as past due and retries the charge over the next days. Until a payment succeeds, requests that need your paid plan get this error. That covers requests beyond the Free plan's monthly credits, and endpoints that are not on the Free plan.

## How to fix

1. Open `billingUrl`, or go to **Settings → Billing** in the [dashboard](https://dash.supadata.ai).
2. Update your card or pay the open invoice.

Your plan and its credits come back as soon as the payment succeeds. You don't need to change your API key or your code.

### Handling it in code

Treat `payment-failed` as a non-retryable error. Retrying won't help until the payment is fixed. Alert whoever manages billing and include `billingUrl`.

### Reach out to support

If the payment keeps failing or you think this is a mistake, contact [support@supadata.ai](mailto:support@supadata.ai) and we will help as soon as possible.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.