ICR (Insulin-to-Carbohydrate Ratio) Calculator
Quickly estimate insulin to cover carbs and correct current blood glucose.
The ICR (Insulin-to-Carbohydrate Ratio) calculator estimates how many units of insulin are needed to cover the carbohydrates you plan to eat and to correct a high blood glucose level, producing an easy-to-read recommended insulin dose.
How to use the ICR calculator — practical guide and explanation
Managing insulin dosing is a daily task for many people with diabetes. The ICR calculator is a practical tool that helps you convert planned carbohydrate intake into insulin units and add any correction insulin needed to bring your current blood glucose back toward your target. This guide explains what the calculator does, how it works, how to use it safely, and includes examples to help you get accurate dosing estimates.
What the calculator does (quick overview)
The calculator performs three primary tasks:
- Converts carbohydrate grams into an insulin dose using your ICR (grams of carbohydrate covered by 1 unit of insulin).
- Calculates a correction dose based on the difference between your current blood glucose and your target glucose using your Insulin Sensitivity Factor (ISF).
- Subtracts active/on-board insulin (insulin already in your body) from the combined dose to avoid stacking and reduce the risk of hypoglycemia.
The result is a suggested insulin dose shown both numerically and visually using a Plotly.js chart so you can easily see the contribution of carbs, corrections, active insulin, and the final net dose.
Inputs explained (what to type in)
Before you press Calculate, enter the following values:
Carbohydrates (g)
Enter the grams of digestible carbohydrates you plan to eat. Use nutrition labels or carb-counting resources to estimate this.
ICR (grams per unit)
This is your personalized Insulin-to-Carbohydrate Ratio. For example, ICR = 10 means 1 unit of insulin covers 10 g of carbs. If you’re unsure, use the value provided by your diabetes team or recent dose records.
Current and Target Blood Glucose (mg/dL)
Your current BG reading (glucometer/cgm) and the BG target you aim for. These drive the correction calculation.
ISF (Insulin Sensitivity Factor)
This is how many mg/dL 1 unit of insulin will lower your blood glucose. If you don’t know it, consult your clinician — a typical range might be 30–80 mg/dL per unit, but it is highly individual.
Active/On-board insulin
The estimated units of insulin still active in your body from recent injections or boluses (often called insulin on board, IOB). Enter the estimated units to avoid overdosing.
How the calculation works (simple math)
- Carb insulin = Carbs ÷ ICR
- Correction insulin = max(0, (Current BG − Target BG) ÷ ISF)
- Total recommended insulin = max(0, Carb insulin + Correction insulin − Active insulin)
The calculator rounds results and displays them in a small results panel and a Plotly.js bar chart with four bars: Carb insulin, Correction insulin, Active insulin, and Net dose.
Step-by-step usage example
Suppose you plan to eat 60 g carbs, your ICR is 10, current BG is 150 mg/dL, target is 100 mg/dL, ISF is 50 mg/dL per unit, and active insulin is 0 U.
- Carb insulin = 60 ÷ 10 = 6.0 U
- Correction insulin = (150 − 100) ÷ 50 = 1.0 U
- Total = 6.0 + 1.0 − 0 = 7.0 U
The calculator displays “Total recommended insulin: 7.00 U” and a bar chart that visually shows the 6 U from carbs, 1 U from correction, 0 U active, and a net 7 U.
Visual feedback with Plotly.js
The chart gives immediate visual confirmation of how the total dose is composed. This helps you quickly spot large corrections or unexpected high carb doses. Because the chart is built with Plotly.js, it is responsive and interactive — hover to see precise values.
Safety tips and best practices
- Always follow your healthcare provider’s guidance. This tool provides an estimate; it is not a replacement for medical advice.
- Accurately estimate carbs and active insulin — errors in those values create dose errors.
- If you have recent insulin activity (within the last 3–4 hours), include it to reduce risk of stacking insulin.
- For low blood glucose (<70 mg/dL) or when you suspect hypoglycemia, do not use a bolus — treat the low first.
- If you’re changing your ICR or ISF, make adjustments slowly and under clinical supervision.
Troubleshooting
- If the chart does not appear, ensure Plotly’s CDN script is loading and there are no content security policy (CSP) restrictions on your site.
- If numbers look off, double-check units: mg/dL vs mmol/L. This calculator assumes mg/dL. If you use mmol/L, convert first.
- If you see a negative total dose, the calculator will display 0.0 U as the recommended dose because active insulin can entirely cover the carbs + correction.
FAQ
Q: What is ICR and why is it important?
A: ICR (Insulin-to-Carbohydrate Ratio) tells you how many grams of carbohydrate are covered by one unit of insulin. It helps people with insulin therapy dose correctly for meals and maintain blood glucose control.
Q: Can I use mmol/L instead of mg/dL?
A: No — this calculator uses mg/dL. If you use mmol/L, convert (multiply mmol/L by 18 to get mg/dL) before entering values.
Q: Is this tool a replacement for medical advice?
A: No. It’s an estimating tool to aid in calculations. Consult your diabetes team for personal targets, ICR, and ISF settings.
Q: Why does the chart show negative values sometimes?
A: The calculator prevents a negative final dose by flooring the net dose to zero; active insulin can offset carb + correction insulin. The plotted values still display active insulin as a positive bar to show contribution.
Q: Can the calculator be customized?
A: Yes. Because it’s a single HTML file using Plotly.js, you can modify styling, default values, units, or integrate it with other plugins on your WordPress site. If you need help customizing, tell me what changes you want.