Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 7 additions & 11 deletions overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -73,21 +73,17 @@ Build, analyze, and innovate with X's real-time global data. Access posts, users
The X API uses **pay-per-usage** pricing. No monthly subscriptions—pay only for what you use.

<CardGroup cols={2}>
<Card title="Flexible" icon="sliders">
Scale up or down based on your needs. Costs grow with your usage.
<Card title="Pay-per-usage" icon="coins" href="/x-api/getting-started/pricing">
Flexible, credit-based pricing. Scale up or down based on your needs with no commitments or minimum spend.
</Card>
<Card title="Accessible" icon="door-open">
Lower barriers for small projects. No tier jumps or commitments.
<Card title="Enterprise" icon="building" href="/forms/enterprise-api-interest">
Dedicated support, complete streams, and custom integrations for high-volume needs.
</Card>
</CardGroup>

<div className="mt-4">
<Button href="https://console.x.com">View pricing in Developer Console</Button>
</div>

For enterprise needs with dedicated support, complete streams, and custom integrations:

<Button href="/enterprise/forms/enterprise-api-interest">Contact Enterprise Sales</Button>
<Tip>
Earn free [xAI API](https://docs.x.ai) credits when you purchase X API credits—up to 20% back based on your spend. [Learn more](/x-api/getting-started/pricing#free-xai-api-credits)
</Tip>

---

Expand Down
44 changes: 43 additions & 1 deletion x-api/getting-started/pricing.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: Pricing
sidebarTitle: Pricing
description: Pay-per-usage pricing for the X API
keywords: ["X API pricing", "API pricing", "pay-per-usage", "API credits", "billing", "deduplication", "API costs", "auto-recharge", "spending limit", "spend cap"]
keywords: ["X API pricing", "API pricing", "pay-per-usage", "API credits", "billing", "deduplication", "API costs", "auto-recharge", "spending limit", "spend cap", "xAI credits", "free credits", "Grok API"]
---

import { Button } from '/snippets/button.mdx';
Expand Down Expand Up @@ -30,6 +30,10 @@ The X API uses **pay-per-usage** pricing. No subscriptions, no monthly caps—pa
</Card>
</CardGroup>

<Tip>
Earn free [xAI API](https://docs.x.ai) credits when you purchase X API credits—up to 20% back based on your spend. [Learn more](#free-xai-api-credits)
</Tip>

---

## Deduplication
Expand Down Expand Up @@ -86,6 +90,44 @@ Use spending limits to prevent unexpected charges, especially during development

---

## Free xAI API Credits

When you purchase X API credits, you can earn free [xAI API](https://docs.x.ai) credits based on your cumulative spend during a billing cycle.

### How it works

Your cumulative spend is tracked throughout each billing cycle. As you cross spending thresholds, you unlock higher reward rates. When a new billing cycle starts, your cumulative spend resets to $0.

| Cumulative spend | Rate |
|:-----------------|:-----|
| &dollar;0 – &dollar;199 | 0% |
| &dollar;200 – &dollar;499 | 10% |
| &dollar;500 – &dollar;999 | 15% |
| &dollar;1,000+ | 20% |

<Note>
The rate applies to your **entire cumulative balance**, but you only receive the delta—what's newly owed minus what was already credited.
</Note>

### Example

Suppose you make two purchases in the same billing cycle:

| Purchase | Cumulative spend | Rate | Total owed | Already credited | You receive |
|:---------|:-----------------|:-----|:-----------|:-----------------|:------------|
| &dollar;200 | &dollar;200 | 10% | &dollar;20 | &dollar;0 | **&dollar;20** |
| &dollar;300 | &dollar;500 | 15% | &dollar;75 | &dollar;20 | **&dollar;55** |

**Total xAI credits received: $75**

This is the same amount you'd receive from a single $500 purchase—the order and size of purchases doesn't affect your total rewards.

<Tip>
View your xAI credit balance and manage your account at [console.x.ai](https://console.x.ai). For more details on xAI API billing, see the [xAI billing documentation](https://docs.x.ai/docs/key-information/billing).
</Tip>

---

## Monitoring usage

Track your API usage programmatically with the [Usage endpoint](/x-api/usage/introduction):
Expand Down
4 changes: 4 additions & 0 deletions x-api/introduction.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ The X API uses **pay-per-usage** pricing. No subscriptions, no monthly caps—pa
</Card>
</CardGroup>

<Tip>
Earn free [xAI API](https://docs.x.ai) credits when you purchase X API credits—up to 20% back based on your spend. [Learn more](/x-api/getting-started/pricing#free-xai-api-credits)
</Tip>

<div className="mt-6 flex gap-4">
<Button href="/x-api/getting-started/pricing">Pricing details</Button>
<Button href="https://console.x.com">Purchase credits</Button>
Expand Down