Check Treasury debt data, then make the snapshot repeatable
A debt number is useful only with its definition and date. Here is a short path from a free public snapshot to a local, scriptable record you can reproduce later.
Know which debt number you are reading
The Treasury's Debt to the Penny dataset separates debt held by the public from intragovernmental holdings. Their sum is total public debt outstanding. A chart, report, or script that labels all three simply “national debt” can obscure which series changed.
The dataset is reported each business day with data for the previous business day. That means a retrieval time and a record date are different. Keep both in any copied table or automated summary, and check the source's update note before treating a missing weekend row as a data error.
Start with a free snapshot
Our free US national debt and Treasury snapshot shows the latest available public figures without requiring an account. Use it to see the field names, source dates, and current response before you wire the same data into a script.
Check the free Treasury snapshot →
Verify the record date and series against Treasury's own explanation of the national debt when you quote a figure.
Make a repeatable local record
For a report, scheduled job, or agent workflow, retain the raw value, unit, source URL, record date, and retrieval time. Compare like with like: public debt held by the public should not be silently compared with total public debt outstanding. If you join debt with interest or cash series, check each series' own coverage and update schedule.
- Run a sample first so the output shape is clear.
- Fetch the current public data when the job needs freshness.
- Store the source and date alongside each value.
- Use JSON output for downstream scripts, and recheck key figures at Fiscal Data before publication.
treasury-watch is a standard-library Python CLI for that local workflow. It includes an offline sample and an optional public Fiscal Data refresh, then prints a readable snapshot or JSON. The sample is for testing, not a claim about today's debt.
Local Treasury snapshot CLI: $9 suggested price, $5 minimum.
For per-call agent access instead of a download, see the paid Treasury snapshot API (x402, USDC on Base). Prefer card billing? Subscribe on RapidAPI for the same snapshot endpoint. The shop lists all current products and prices.
Independent public-data helper. This page and its linked tools are not official Treasury software or financial, tax, legal, or investment advice. Figures can be delayed or revised; verify them at Fiscal Data before using them in a report or decision.