ForHosting KIT · Developer Utilities

Cross exchange rate calculator

A cross exchange rate connects two currencies that are each quoted against the same third currency.

● BetaFree · in your browser
Use it from WebAPIEmailTelegramApp soon

Enter the base and quote currency codes, identify their common currency, and supply how many units of that common currency equal one unit of each currency. The calculator divides those compatible quotes to produce the number of quote-currency units per base-currency unit, plus the reciprocal rate. It validates currency codes and rejects zero rates before division. Automated API use costs $0.002 per request.

Read both input rates in the same direction

A reliable cross calculation starts with quote direction. This calculator expects both supplied rates to use the same convention: common-currency units per one unit of the named currency. For example, if the base currency is EUR, the quote currency is GBP, and the common currency is USD, base_rate means USD per EUR and quote_rate means USD per GBP. Do not enter one rate as USD per EUR and the other as GBP per USD, because those values point in opposite directions and cannot be divided directly. Currency codes are normalized to uppercase, but each must contain exactly three letters. The common currency must also differ from both currencies being crossed, and the base and quote currencies must differ from each other. These rules make the returned meaning unambiguous: cross_rate always reports quote-currency units for one base-currency unit, while inverse_rate reports base-currency units for one quote-currency unit. Before calculating, write a short unit label beside each source rate; matching denominators reveal whether they are compatible.

Understand the division and reciprocal

When both quotes share the common currency in the numerator, that common unit cancels during division. The calculator computes base_rate divided by quote_rate. Suppose one EUR equals 1.08 USD and one GBP equals 1.26 USD. Dividing 1.08 USD per EUR by 1.26 USD per GBP cancels USD and leaves GBP per EUR. The reciprocal is calculated independently as quote_rate divided by base_rate, producing EUR per GBP. Returning both directions helps prevent a frequent operational mistake: taking a correct rate and applying it backward in an invoice, ledger, or spreadsheet. The formula string in the output records the currency order used, so the numerical result retains its interpretation when copied elsewhere. Results are rounded only to a stable significant-digit representation for consistent JSON output; the calculator does not impose a market-specific display precision. For settlement or accounting, apply the decimal-place and rounding policy required by your institution after obtaining the mathematical cross rate.

Validate source data before using the result

Cross rates are only as current and trustworthy as their two source quotes. This capability performs no network request and does not claim that supplied figures are live market prices. Use rates from the same provider, valuation timestamp, market convention, and rate category whenever the result supports a financial process. Mixing a retail sell rate with an interbank midpoint can produce a mathematically valid but commercially misleading cross. Both rate values must be finite numbers greater than zero. A zero receives a specific input error rather than causing division by zero, and negative or nonnumeric values are rejected because ordinary currency prices cannot usefully have those forms here. The deterministic calculation is suitable for reproducible workflows: the same JSON input always yields the same JSON output. Store the original two quotes, their source and timestamp beside the returned cross rate if auditability matters. Also remember that a theoretical cross can differ from an executable dealer quote because spreads, fees, liquidity, minimum trade sizes, and rounding are outside this calculator’s scope.

Build a spreadsheet cross rate

Check the rate between two currencies when a worksheet already contains each currency's compatible quote against one shared currency.

Reconcile multicurrency records

Derive a consistent conversion factor for comparing ledger values sourced from the same reporting-currency rate table.

Verify a quoted conversion

Compare a dealer or system cross rate with the mathematical rate implied by two common-currency quotes before considering spreads and fees.

What does the API request cost?

Each API request costs $0.002. The calculation is also available in the browser for supported free use.

Which direction should the rates use?

Both must be common-currency units per one unit of the associated base or quote currency.

Why are zero rates rejected?

A zero exchange rate is not meaningful for this calculation and would make one direction involve division by zero.

Does this fetch live foreign-exchange prices?

No. It uses only the rates you supply and makes no network requests.

What does cross_rate mean?

It is the number of quote-currency units equal to one unit of the base currency.

Are fees or bid-ask spreads included?

No. The result is the arithmetic cross implied by the inputs; provider fees, spreads, and settlement rules remain separate.

Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.

POSThttps://api.kit.forhosting.com/econ/cross-exchange-rate

Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.

curl -X POST https://api.kit.forhosting.com/econ/cross-exchange-rate \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"base_currency":"EUR","quote_currency":"GBP","common_currency":"USD","base_rate":1.08,"quote_rate":1.26}'
{
  "base_currency": "EUR",
  "quote_currency": "GBP",
  "common_currency": "USD",
  "base_rate": 1.08,
  "quote_rate": 1.26
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "econ.cross_exchange_rate",
  "status": "queued",
  "_links": {
    "result": "/tasks/tsk_…/result"
  }
}

The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

Read the full KIT documentation →