AGI
Work out the AGI that anchors the rest of a tax return: gross income of 85,000 minus 2,500 of student loan interest and 6,500 of IRA contributions leaves 76,000. Standard deductions and credits come later and stay out. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Runs in your browser. Free, unlimited — your data never leaves this page.
The adjusted gross income calculator takes your gross income and a list of above-the-line deductions — student loan interest, IRA contributions, educator expenses, health savings account contributions and similar items — and returns the AGI that anchors the rest of a tax return. AGI is the figure that determines eligibility for credits, deduction phase-outs and many state tax calculations, so getting it right matters before anything downstream is computed. The same deterministic code runs free in your browser on this page, so you only pay when you automate it.
What adjusted gross income actually is
Adjusted gross income is not a guess or an estimate — it is a defined subtraction. Start from gross income, which is the sum of everything earned in the period: wages, self-employment receipts, interest, dividends, rental income, retirement distributions and any other taxable inflow. From that total, tax rules allow a specific list of subtractions called above-the-line deductions, because they are taken before the adjusted gross income line on the return rather than after it.
Common members of that list include student loan interest, contributions to traditional IRAs and health savings accounts, the deductible part of self-employment tax, educator expenses, and alimony paid under older agreements. What remains after subtracting them is the AGI. The adjusted gross income calculator performs exactly that operation: it takes the gross figure and the itemized deductions, validates each entry, and returns the difference.
It does not apply standard or itemized deductions, filing status rules or credits — those all come after AGI, and conflating them with AGI is the single most common mistake in informal tax math.
Where AGI fits in real workflows
AGI is the hinge figure of a tax return: eligibility for education credits, Roth IRA contributions, premium tax credits and many deduction phase-outs is expressed as a threshold on AGI or on modified AGI, which starts from it. Payroll and benefits tools recompute it when an employee adjusts a pre-tax contribution; financial aid forms ask for it verbatim; lenders use it as a sanity check against stated income.
Embedding this calculator in those flows replaces a spreadsheet cell with a validated contract: the caller gets either a correct AGI or a clear error naming the offending field, never a plausible-looking wrong number.
What you can do with it
Estimate tax-credit eligibility
Compute AGI first, then check it against the phase-out thresholds for education credits or retirement contribution limits.
Model a pre-tax contribution change
Add or remove an IRA or HSA contribution from the deduction list and see immediately how the AGI moves.
FAQ
Which deductions count as above-the-line?
Items such as student loan interest, traditional IRA and HSA contributions, educator expenses and the deductible part of self-employment tax. The tool accepts any list you provide; deciding what qualifies is your tax advisor's job.
What happens if deductions exceed gross income?
AGI from above-the-line deductions alone cannot go below zero, so that situation means the inputs were mixed up.
Are negative amounts allowed?
No. Gross income and every deduction amount must be zero or positive and finite.
Is my income data stored?
No. The numbers are processed in memory and discarded; only the computed result is returned.
Does it compute taxes owed or refunds?
No. It stops at AGI. Taxable income, tax brackets, credits and refunds all come after AGI and are outside the scope of this capability.
Related tools
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/fin/agi \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"gross_income":85000,"deductions":[{"label":"student loan interest","amount":2500},{"label":"traditional IRA contribution","amount":6500}]}'const res = await fetch("https://api.kit.forhosting.com/fin/agi", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"gross_income": 85000,
"deductions": [
{
"label": "student loan interest",
"amount": 2500
},
{
"label": "traditional IRA contribution",
"amount": 6500
}
]
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/fin/agi",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"gross_income": 85000,
"deductions": [
{
"label": "student loan interest",
"amount": 2500
},
{
"label": "traditional IRA contribution",
"amount": 6500
}
]
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/fin/agi", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"gross_income":85000,"deductions":[{"label":"student loan interest","amount":2500},{"label":"traditional IRA contribution","amount":6500}]}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"gross_income":85000,"deductions":[{"label":"student loan interest","amount":2500},{"label":"traditional IRA contribution","amount":6500}]}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/fin/agi", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"gross_income": 85000,
"deductions": [
{
"label": "student loan interest",
"amount": 2500
},
{
"label": "traditional IRA contribution",
"amount": 6500
}
]
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "fin.agi",
"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. |
Technical notes
You send the gross income and the deductions as structured data; the API validates every value, sums the deductions, subtracts them and returns the AGI along with the itemized breakdown.
How the computation and its validation work
The computation is pure arithmetic with no network calls, no randomness and no clock, which means the same request always produces the same response — a property that matters when a result has to be reproduced months later during a review or an audit. The endpoint accepts two fields: a gross income figure and an array of deduction records, each with a label and an amount. Every number must be finite and zero or positive — a negative deduction is not a credit, it is a data error, and the API says so instead of silently adding income. The deduction amounts are summed and compared against gross income: when the total exceeds what was earned, the request is rejected with a typed error, because an AGI below zero from above-the-line deductions alone indicates that the inputs were mixed up, typically by including below-the-line items such as the standard deduction or mortgage interest. When the inputs pass, the response returns the AGI, the gross income, the total deductions, and the itemized list as received, all rounded to two decimal places so the output is byte-stable across machines and safe to store in an audit trail.
Where AGI fits in real workflows
Because the same module runs in the browser on this page, a developer can paste the exact payload their integration will send and confirm the result before writing any code. The API then charges $0.002 per request for the identical answer, with no minimums and no data retained — the numbers are processed and discarded, and only the computed result travels back to the caller.
Integration use cases
Validate figures before filing
Send the gross income and deductions exactly as gathered and let the API catch negative amounts or deductions that exceed income.
Technical questions
What does it cost?
$0.002 per request. It is also free to run in your browser on this page — the same code produces both answers.