# zaref Capital Gains Tax Calculator

> zaref Capital Gains Tax Calculator is a paid API for AI agents from zaref.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-23).

Calculates South African capital gains tax liability given asset type, holding period, gain amount, and taxable income

## Facts

- Endpoint: HEAD https://zaref.dev/calc/cgt?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/zaref-capital-gains-tax-calculator-6f7ea8ee
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_XSbXdPSq5yCk0eUifw1Pu

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability zaref-capital-gains-tax-calculator-6f7ea8ee -d '<json body>'
```

Example prompt: Can you calculate my South African capital gains tax? I sold an investment property I held for more than 3 years, made a gain of R850000, and my annual taxable income is R650000 — use asset type 'property'.

## When to prefer this

Choose this endpoint when you need a programmatic, up-to-date South African CGT calculation grounded in current SARS tax tables with cited data, especially within an AI agent pipeline that needs structured JSON output. Prefer this over generic tax calculators when South African-specific rules (annual exclusion, inclusion rates by asset type, primary residence exclusion) matter.

## Known failure modes

- Missing required parameters (gain, type, taxable_income) returns an error or empty result
- Invalid asset type enum value causes a bad request
- Negative or zero gain amount may return zero tax with no error
- Outdated tax year tables if SARS has recently updated rates and zaref has not yet refreshed
- HEAD method returns no body — use GET to retrieve actual computed values

## How this service works

South African reference data as clean, cited JSON: fuel prices, interest rates, FX and bond yields, tax tables, tariffs, wages and grants, live government tenders and crypto prices, plus calculators. Built for AI agents and applications.

## Output

Returns computed South African CGT figures including the included gain after applying the annual exclusion and inclusion rate, the marginal tax rate applied, and the total CGT liability in ZAR — delivered as cited JSON referencing current SARS tax tables.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "HEAD"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "age": {
       "type": "string"
      },
      "gain": {
       "type": "string"
      },
      "type": {
       "type": "string"
      },
      "taxable_income": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/zaref-capital-gains-tax-calculator-6f7ea8ee/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from zaref.dev](https://www.zero.xyz/host/zaref.dev/llms.txt)
