I'm making a number of small devices such as temperature sensors, RF433 transmitter and receiver (for controlling and receiving devices => MQTT) mostly using EPS8266.

They work fine, and are USB powered because it's simple and works. They probably all use too much power to run off batteries but it would be nice if I could incorporate perhaps a small rechargable battery so that my temperature sensor for example could continue to work for a day or two if unplugged.

I could make something, but does anyone know of anything very cheap that is a plug in solution for this kind of thing. Small and cheap are essential.


4 Answers 4


You can hook up a USB battery pack to both the Pi and the charger (as long as it is designed to charge while being used) and if the power goes out the USB battery pack will take over powering the Pi directly.

Search for "USB UPS" and you will find tons of info on individual setups.

  • 2
    Welcome to IoT! It might be a nice idea to link a few of the UPS devices you're talking about to save people a click, but I think the answer's spot on with the idea.
    – Aurora0001
    Commented Dec 13, 2016 at 15:35

If possible choose a device that has a built in battery. A few such examples that use the common 2-pin JST connector. The first two are based off of the esp8266


pcb of the wiolink


pcb of wio node

C.H.I.P ($9 computer)

C.H.I.P. pcb with battery pack

Raspberry Pi Zero + battery module Raspberry Pi zero with battery pack


The smaller and cheaper way to supply power to wireless devices is to reduce power consumption as much as possible in the first place. Designing for low power is less convenient that not caring for it, but to give you an idea, a well designed wireless temperature sensor should probably last a couple of years on a CR2032 battery costing cents, where you will spend hundreds times that on a charger and not-so-tiny battery for a system that will have to be charged daily.

To learn low power design, have a look at this website (lots of interesting projects in the archive).


You can switch over from main power to battery backup using a couple of diodes, for example like this.

I did something similar with a 15 V transformer and a 12 V car battery: as long as the mains power is on, the diode to the battery is reverse-biased, and no current flows from the battery into the circuit. When the main power fails, the cut-over to the battery is automatic.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.