{"uid":"cap_cO5F_OWFlm6VAO4msBK4O","slug":"battery-runtime-calculator-1f4976c6","name":"Battery Runtime Calculator","description":"Battery runtime estimate from capacity (mAh and volts, or Wh) and load (mA or W), with efficiency and usable depth of discharge.","url":"https://electronics-calc.x402tookit.com/battery-runtime?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":[],"properties":{"loadW":{"type":"number","description":"Load in watts (instead of mA)"},"loadMa":{"type":"number","description":"Load in mA at the battery voltage"},"voltage":{"type":"number","description":"Battery nominal volts (with mAh)"},"usablePct":{"type":"number","description":"Usable capacity, default 80 (protects battery life)"},"capacityWh":{"type":"number","description":"Capacity in watt-hours (instead of mAh)"},"capacityMah":{"type":"number","description":"Capacity in mAh (with voltage)"},"efficiencyPct":{"type":"number","description":"Converter efficiency, default 90"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","properties":{"asOf":{"type":["null","string"]},"loadW":{"type":["null","number"]},"source":{"type":["null","string"]},"reasons":{"type":["array","null"],"items":{"type":"string"}},"summary":{"type":["null","string"]},"verdict":{"type":["null","string"]},"degraded":{"type":["boolean","null"]},"capacityWh":{"type":["null","number"]},"disclaimer":{"type":["null","string"]},"efficiency":{"type":["null","number"]},"idealHours":{"type":["null","number"]},"notChecked":{"type":["array","null"],"items":{"type":"string"}},"estimatedDays":{"type":["null","number"]},"estimatedHours":{"type":["null","number"]},"usableFraction":{"type":["null","number"]},"estimatedMinutes":{"type":["null","number"]}}}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_AxSb7VjD3KlgQ2OCZvaU3","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Estimates how long a battery will last given its capacity (mAh/V or Wh), load (mA or W), converter efficiency, and usable depth of discharge.","exampleAgentPrompt":"How long will a 10000 mAh battery at 3.7V last powering a device that draws 250 mA, assuming 85% converter efficiency and 80% usable capacity?","exampleUseCases":[{"title":"IoT sensor battery life planning","prompt":"I have a 3.7V 2000 mAh LiPo battery powering a sensor that draws 15 mA continuously. With 90% efficiency and 80% usable depth of discharge, how many hours will it run?"},{"title":"Portable power bank runtime for laptop","prompt":"My power bank is rated at 20000 mAh at 3.7V and my laptop pulls 45W. Can you estimate how long the power bank will last, using 88% efficiency and 80% usable capacity?"},{"title":"Solar backup system sizing check","prompt":"I have a 100Wh battery pack and a device running at 8W. With 90% efficiency and 90% usable capacity allowed, how many hours of runtime should I expect?"}],"resultDescription":"Returns estimated battery runtime as hours, minutes, and days alongside supporting values: load in watts, effective capacity in watt-hours, usable fraction applied, efficiency factor, a plain-English summary, and a disclaimer about real-world variation.","failureModes":["Missing both capacity inputs (neither mAh+voltage nor Wh provided) returns an error","Missing both load inputs (neither mA nor W) returns an error","Zero or negative values for capacity or load produce invalid/error responses","Efficiency or usable percentage outside 0-100 range may produce unexpected results","Conflicting inputs (e.g. both mAh and Wh with inconsistent values) may yield unexpected results"],"whenToPreferThis":"Use this endpoint when you need a quick, parametric battery runtime estimate during circuit design, product planning, or field deployment — especially when you need to account for converter efficiency losses and depth-of-discharge constraints. Prefer this over manual spreadsheet calculations or generic formulas when you want a structured JSON result with summary text and multiple time-unit outputs.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-26T00:35:36.119Z","isFirstParty":false,"canonicalSlug":"battery-runtime-calculator-1f4976c6"}