Marginal Revenue from Total Revenue Calculator
Marginal revenue measures how much total revenue changes for each additional unit represented by the movement between two sales levels.
Run — free
Enter total revenue and quantity for an initial level and a second level, and the calculator applies the difference quotient: change in total revenue divided by change in quantity. The result can be positive, zero, or negative, helping you see whether the observed sales change added revenue per unit, left it unchanged, or reduced it. Equal quantities are rejected because division by a zero quantity change is undefined.
What marginal revenue means between two observed sales levels
Marginal revenue describes the additional total revenue associated with an additional unit of quantity. When only two observed sales levels are available, it is calculated as a discrete change rather than as a derivative: subtract the first total revenue from the second, subtract the first quantity from the second, and divide the revenue change by the quantity change. For example, the two levels might represent sales before and after a price adjustment, two production plans, or neighboring points in a demand schedule. The result is an average marginal revenue across that interval, not necessarily the exact revenue from one particular unit inside it. A positive result means total revenue and quantity moved in a direction that produces positive revenue per added unit. A negative result can occur when selling more requires a price reduction large enough to decrease total revenue, or when the observations are entered in reverse order but their relative movements differ. A zero result means quantity changed while total revenue did not. Interpret the output in the same currency used for total revenue per quantity unit used in the inputs.
How to enter the figures and read the calculation
Use total_revenue_1 and quantity_1 for one sales level, then total_revenue_2 and quantity_2 for the comparison level. Both observations must use the same currency basis, accounting period, revenue definition, and quantity unit. Gross revenue should not be compared with net revenue, monthly figures should not be mixed with weekly figures, and individual products should not be mixed with cartons unless you first convert them. The calculator returns change_in_total_revenue, change_in_quantity, and marginal_revenue so the arithmetic remains visible rather than presenting an unexplained final number. It preserves the direction of subtraction: each change is the second value minus the first. This means you may compare a higher sales level with a lower one, and the signs will still communicate the direction of movement. Quantity values must differ. If they are equal, the denominator is zero, so no finite marginal revenue can be computed from those observations. All four inputs must be finite numbers; omitted values, numeric strings, infinity, and nonnumeric text are rejected instead of being silently converted.
Using the result for pricing and operating decisions
Marginal revenue is most useful when paired with marginal cost over a comparable interval. If marginal revenue exceeds marginal cost, the observed increase in quantity may contribute toward profit; if marginal cost exceeds marginal revenue, expanding along that interval may reduce profit. That comparison still requires care. This calculator does not infer demand, isolate causation, estimate marginal cost, or recommend a price. Promotions, seasonality, product mix, refunds, taxes, channel fees, and capacity constraints can all change total revenue between observations. Use points that are economically comparable and document what changed between them. For a nonlinear revenue curve, calculate several adjacent intervals rather than treating one wide interval as representative of every unit. Smaller, reliable intervals usually give a more local view, while wider intervals provide a broader average. The calculation is deterministic and runs without network access, so the same four values always produce the same result. Browser use is free, while an API calculation is priced at $0.002 per request for repeatable spreadsheet, reporting, or planning workflows.
What you can do with it
Compare adjacent demand schedule points
Calculate the revenue gained or lost per unit between neighboring quantity and total revenue observations.
Evaluate a sales-volume change
Measure the average incremental revenue associated with moving from one recorded sales level to another.
Prepare a marginal cost comparison
Produce a transparent marginal revenue figure to compare with marginal cost over the same quantity interval.
FAQ
What formula does the calculator use?
It uses (total_revenue_2 - total_revenue_1) divided by (quantity_2 - quantity_1).
Why must the two quantities be different?
Equal quantities create a zero denominator. Marginal revenue is undefined when there is no change in quantity.
Can marginal revenue be negative?
Yes. It is negative when the change in total revenue and the change in quantity have opposite signs.
Is this the revenue from exactly one additional unit?
Not necessarily. With two sales levels, the result is the average change in total revenue per unit across the interval between them.
Which currency does the result use?
It uses whichever currency you use consistently for both total revenue inputs, expressed per quantity unit.
How much does an API calculation cost?
Each API request costs $0.002. The calculation can also run free in the browser.
For developers — API access
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.
API endpoint
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.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/econ/marginal-revenue-from-total \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"total_revenue_1":1200,"total_revenue_2":1650,"quantity_1":100,"quantity_2":130}'const res = await fetch("https://api.kit.forhosting.com/econ/marginal-revenue-from-total", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"total_revenue_1": 1200,
"total_revenue_2": 1650,
"quantity_1": 100,
"quantity_2": 130
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/econ/marginal-revenue-from-total",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"total_revenue_1": 1200,
"total_revenue_2": 1650,
"quantity_1": 100,
"quantity_2": 130
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/econ/marginal-revenue-from-total", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"total_revenue_1":1200,"total_revenue_2":1650,"quantity_1":100,"quantity_2":130}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"total_revenue_1":1200,"total_revenue_2":1650,"quantity_1":100,"quantity_2":130}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/econ/marginal-revenue-from-total", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"total_revenue_1": 1200,
"total_revenue_2": 1650,
"quantity_1": 100,
"quantity_2": 130
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "econ.marginal_revenue_from_total",
"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.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |