All posts

How to Add a Battery to Your Hardware Product: LiPo, Charging, and Runtime (2026)

Almost every founder I talk to hits the same wall at the same moment. The prototype works on a desk, plugged into a laptop, and then somebody asks the obvious question: how does this thing run without a cord? That is when you find out that adding a battery to your hardware product is not one decision. It is about five of them, and they are all tangled together.

None of it is hard once you see the shape of it. The trouble is that the parts people skip are the ones that brick prototypes. Here is the whole picture, in the order you actually have to decide it.

Quick answer

If you want the short version before the details:

  • Use a single lithium polymer cell with a built in protection circuit. A 1,200 mAh cell runs about $9.95 at Adafruit in ones and twos.
  • Charge it with a dedicated charger IC fed from USB-C. Do not try to charge lithium with a resistor and hope.
  • Regulate down to your logic rail. Use a low dropout regulator (LDO) if your load is small, a buck converter if it is not.
  • Runtime is average current, not peak current. Peak current is a separate problem that causes resets.
  • Budget roughly $2,000 to $7,000 and a month or two for UN 38.3 shipping tests, but only when you are shipping real units, not prototypes.

The five blocks in a battery powered product

Every battery powered product I have built or reviewed has the same chain in it. If you can name these five blocks, you can talk to a contract engineer without feeling lost.

Block diagram of the five blocks in a battery powered hardware product: USB-C input, charger IC, protected Li-ion cell, regulator, and load

The one people leave out is the protection circuit, because on a cheap cell it is a tiny board hidden under the yellow tape and it is easy to assume it is always there. It is not. Bare cells exist, they are cheaper, and they will happily discharge into a short until something melts. Buy cells with protection built in.

Pick the cell before you pick anything else

Battery choice constrains your enclosure, charge time, runtime and shipping rules, so it goes first. For a first product, a single lithium polymer pouch cell is almost always right. It is flat, it comes in hundreds of sizes, and one cell gives you 3.0V to 4.2V, which most modern parts are happy with.

Real prices, today, in single quantities: 1,200 mAh for $9.95 in a 34 by 62 by 5 mm pouch, or 2,500 mAh for $14.95 in a 50 by 60 by 7.3 mm pouch. At volume you will pay a fraction of that, but these are the numbers for your first ten units.

Capacity is roughly proportional to volume, so the only ways to double runtime are a bigger product or less power. Thickness is what usually kills a design, because 7.3 mm of cell plus a board plus wall thickness adds up fast. Measure the cell before you draw the enclosure, not after.

Charging is one chip and three decisions

Lithium charging sounds scary and is not. A charger IC handles the whole profile: constant current up to a point, then constant voltage, then a clean stop at 4.2V. The classic small part is the MCP73831, which needs about four passives around it. Your three decisions are:

  1. Charge current. Set by a single resistor on most charger ICs. A common rule is half the cell capacity per hour, so a 1,200 mAh cell charges at around 600 mA and fills in roughly two hours. Faster is possible, but the cell datasheet gets a vote.
  2. Where the load sits. If your product has to run while charging, you want a charger with power path management. Otherwise it sees the load as part of the battery and the termination logic gets confused.
  3. Whether the user can see it. One LED on the charger status pin costs nothing and saves a support email every time somebody asks whether the thing is charging.

LDO or buck: the choice that sets your runtime

Your parts probably want a steady 3.3V. Your cell gives you 4.2V falling to 3.0V, so something has to sit in between. An LDO is a simple linear regulator: one chip, two capacitors, no inductor, no layout drama. The catch is that it burns off the difference as heat, so its efficiency is literally the output voltage divided by the input voltage. A buck converter switches instead of burning, which is why a good one lands in the 90 percent range, but it costs more, needs an inductor, and cares about how you lay it out.

Bar chart comparing LDO and buck converter efficiency for a battery powered hardware product at 3.7V and 4.2V input

The honest summary: for a 3.3V rail off a single lithium cell, an LDO throws away only about 11 to 21 percent, and the simplicity is usually worth it. The moment you need a rail well below the cell voltage, or you are pulling serious current, the LDO stops being a rounding error and starts being your battery life.

The runtime math

This is the calculation nobody does before committing to an enclosure size, and it takes thirty seconds. Take your cell capacity, knock off about 20 percent because you cannot use the very top or the very bottom of the curve, then divide by your average current. A 1,200 mAh cell gives you roughly 960 mAh usable. At an average draw of 40 mA, that is about 24 hours. At an average draw of 1 mA, that is about 40 days.

The word doing all the work there is average. A product that wakes up, reads a sensor, sends a packet and goes back to sleep spends almost all of its life asleep, so its sleep current dominates everything. The modern numbers are genuinely good here. Espressif rates deep sleep on the ESP32-C6 at 7 microamps. The nRF52840 spec sheet lists 0.4 microamps in System OFF and a 4.8 mA peak in radio transmit at 0 dBm.

Put that in context: a 960 mAh usable cell driving nothing but 7 microamps would last over a decade on paper. It will not, because the cell self discharges and your other components leak, but the lesson holds. Once you are down at those numbers, battery life is set by how often you wake up and what else is on the board, not by the microcontroller. If you have not picked one yet, I wrote about that tradeoff in how to pick a microcontroller for your first product.

Peak current is what actually kills prototypes

Runtime is an average current problem. Stability is a peak current problem, and they fail in completely different ways. Anything with a radio draws current in violent bursts. ESP32 designs commonly see 400 to 500 mA peaks during Wi-Fi connect and boot. That burst pulls the cell voltage down for a few milliseconds, the rail sags under the brownout threshold, and the chip resets. Then it tries to connect again. You get a device that boot loops the instant you unplug it from USB, which looks like a firmware bug and is not.

Three fixes, in the order I would try them: put real bulk capacitance near the power input, on the order of 470 to 1000 microfarads; make sure your regulator is rated for the peak and not just the average; and check that your cell is big enough to deliver that burst without sagging, because a tiny 100 mAh cell physically cannot source 500 mA cleanly.

When your first assembled units show up, resist the urge to plug the battery straight in. Power it from a bench supply with a current limit first. I walked through that whole sequence in what to do when your board arrives.

The shipping and certification part nobody budgets for

The moment you put a lithium cell in a product and ship it, you are shipping dangerous goods. That is routine, but it has rules and a price tag.

Chart of battery certification costs for a hardware product: UN 38.3, IEC 62133-2 and UL 2054 price ranges

UN 38.3 is the transport test, and you cannot skip it if your product goes on a plane. Published ranges put it at $2,000 to $7,000 over three to six weeks, and Epec quotes $5,000 to $7,000 and 16 sample packs for the same thing. IEC 62133-2 and UL 2054 are separate, cost more, and only come up when a retailer or an enterprise customer asks.

One rule that changed recently and catches people out: as of January 1, 2026, lithium ion batteries packed with equipment above 2.7 Wh have to be offered for air transport at 30 percent state of charge or less. It moved from a recommendation to a requirement in the 67th edition of the IATA rules. If your assembly plan involves shipping finished, fully charged units by air, that is now a plan you need to revisit.

None of this applies to five prototypes you hand to people in your own city. It applies the day you ship a hundred. For the wider picture of what a first run costs, I broke it down in how much it costs to make a hardware prototype.

What I would do for a first prototype

Single lithium polymer cell with protection, sized to fit the enclosure with a few millimeters to spare. USB-C in. A charger IC with a status LED and a resistor set to about half the cell capacity. An LDO to 3.3V if your average draw is under about 100 mA, a buck if it is more. A resistor divider into an analog pin so firmware can read the battery voltage. Bulk capacitance sized for your worst burst.

That is a very ordinary power section, and ordinary is the goal. If you would rather not draw it yourself, this is the kind of thing Tovan does: you describe the product, it picks in-stock parts, draws the schematic, routes the board and fits an enclosure around it. It is not the tool for high speed or RF heavy work. Update, October 2026: it now writes and tests the firmware too, in beta, including the battery-voltage reading. Here's how.

FAQ

Can I just use a USB power bank instead of designing a battery circuit?

For early prototypes, yes. The catch is that most power banks shut off when the load drops below a threshold, which a sleeping low power product trips constantly. Fine demo hack, bad product.

How many lithium cells should I use?

One, unless you have a specific reason not to. Multiple cells in series means balancing, a more complicated protection circuit and more certification scope. One cell plus a boost converter is usually simpler than two cells in series.

Do I need a fuel gauge chip?

Probably not at first. A resistor divider to an analog pin gives you battery voltage, a rough but usable proxy. Dedicated fuel gauge ICs are worth it once users care about the percentage being right.

Why does my product reset when it transmits?

Almost always a peak current problem, not a capacity problem. The radio burst pulls the rail below the brownout threshold. Add bulk capacitance, check the regulator current rating, and check the cell can source the burst.

Is a coin cell an option?

Only for genuinely tiny loads. A CR2032 holds roughly 220 mAh and cannot source large bursts at all, so it suits a device that wakes rarely and sends very little. Anything with Wi-Fi is out.

When do I actually need UN 38.3 testing?

When you are shipping products containing lithium cells commercially, especially by air. Hand carrying a handful of prototypes is a different situation. Ask your freight forwarder before you assume, because the penalty for getting it wrong is a shipment that sits.

Power is one of the few parts of a hardware product where the boring choice is almost always the right one. Pick the cell early, do the runtime arithmetic before you commit to an enclosure, and size for the peak instead of the average.

Keep reading

0 comments

  • No comments yet. Be the first.