A fast, private insulin dose calculator for Android — built by a parent of a child with Type 1 diabetes.
- Insulin Dose Calculation — Computes carb dose, correction dose, and total dose based on your inputs
- Dexcom CGM Trend Arrows — Factor in glucose trends (from rapidly rising to rapidly falling) for more accurate dosing
- Multiple Profiles — Create profiles for breakfast, lunch, dinner, etc. with per-profile carb ratio, correction factor, and target
- 24-Hour Schedule — Assign profiles to time ranges for automatic switching throughout the day
- Dose Rounding — Round to 1u, 0.5u, 0.1u, or 0.05u to match your pen or pump precision
- mg/dL & mmol/L — Switch glucose units anytime; all values and trend adjustments update automatically
- Dark & Light Themes — Dark mode, light mode, or auto (follows system setting)
- 100% Private — No accounts, no data collection, no internet required. All data stays on your device.
- JDK 17+
- Android SDK 35 (platform + build-tools)
# Debug APK
./gradlew assembleDebug
# Release AAB (requires signing config — see below)
./gradlew bundleReleaseRelease builds require a keystore.properties file in the project root:
storeFile=../your-keystore.jks
storePassword=your-password
keyAlias=your-alias
keyPassword=your-passwordThis file is gitignored and never committed.
InsulinCalc/
├── app/
│ ├── build.gradle.kts # App build config + signing
│ └── src/main/
│ ├── AndroidManifest.xml
│ ├── java/.../MainActivity.kt # WebView host activity
│ ├── assets/ # Web app (HTML/CSS/JS)
│ │ ├── index.html
│ │ ├── css/style.css
│ │ ├── js/app.js
│ │ └── img/
│ └── res/ # Android resources (icons, themes)
├── tests/ # Playwright UI tests
├── store-assets/ # Play Store screenshots & graphics
├── build.gradle.kts # Root build config
└── settings.gradle.kts
The app uses a native Android WebView to host the calculator UI. The core logic is vanilla HTML/CSS/JS — no frameworks, no dependencies, no network calls. The native Kotlin shell handles the splash screen, system bar theming, and edge-to-edge display.
UI tests use Playwright across 6 device viewports:
npm install
npx playwright testTo regenerate Play Store screenshots:
npx playwright test tests/screenshots.spec.js --project="Pixel 5"This app helps you make insulin dosing calculations. You are strongly encouraged to confirm any information with your professional healthcare provider. This app is not a medical device and is not intended to replace professional medical advice. Not associated with Dexcom or any other medical provider. For medical emergencies call 911.
MIT






