The Project
Picture this: a storm knocks out the power at 2 AM. You fumble for a flashlight, but the batteries are dead. Or worse, you're in the middle of a home project in the basement, and the breaker trips. That's when you realize how much we depend on the grid. But here's the thing—you don't need to shell out $50 for a store-bought emergency light. With a few hours and some basic electronics, you can build a rechargeable emergency lamp that's more reliable and customizable than anything on the shelf.
This project is perfect for anyone who's ever been caught in the dark—literally. Whether you're a seasoned maker or a curious beginner, building your own emergency light teaches you the fundamentals of battery management, LED driving, and circuit protection. Plus, you'll end up with a device that can run for hours on a single charge, automatically turns on when the power goes out, and can be recharged from any USB port. I've built dozens of these over the years, and I still use the one I made from scrap parts back in 2018. It's saved me countless times during power outages and camping trips.
What You'll Need
Let's talk materials. You don't need a fancy electronics lab—most of these components are available at any hobby electronics store or online. Here's the exact shopping list:
- **Battery**: A 3.7V 18650 lithium-ion cell (rated 2000-3000mAh). These are the same cells used in laptop batteries. Grab a protected one with over-discharge protection—it's safer and lasts longer. Cost: around $5-8.
- **LED**: A 1W or 3W high-power white LED (like the CREE XP-G series). These are bright enough to light up a room but won't drain your battery in an hour. Cost: $2-4.
- **Charging Module**: A TP4056-based USB charging board with battery protection. This little board handles constant current/constant voltage charging and prevents overcharging. Cost: $1-2.
- **Switch**: A small SPST toggle or push-button switch. Go with a latching type so you can leave the light on without holding the button. Cost: $1.
- **Resistor**: A 1-ohm, 1/4W resistor for current limiting. (Value depends on your LED—use an online calculator to be precise.) Cost: $0.10.
- **Wiring**: 22-24 AWG stranded hookup wire, preferably in two colors (red for positive, black for negative). Cost: $3 for a spool.
- **Enclosure**: A small plastic project box (like a Hammond 1591 series) or even a repurposed Altoids tin. Cost: $3-5.
- **Heat Sink**: A small aluminum heatsink for the LED (optional but recommended for long runtime). Cost: $1.
- **Tools**: Soldering iron (25-40W), solder, wire strippers, multimeter, hot glue gun, and a small Phillips screwdriver.
Total cost: roughly $15-25, depending on what you already have. That's a fraction of a commercial unit, and you'll know exactly how it works.
Step-by-Step
Let's build this thing. I'll walk you through each step so you don't end up with a smoking pile of components.
**Step 1: Prepare the battery and charging module.** Start by soldering wires to the TP4056 module's B+ and B- pads. Keep the wires short—about 2 inches. Then, solder the other ends to the 18650 battery's positive and negative terminals. Here's the trick most pros won't tell you: use a battery holder instead of soldering directly to the cell. Soldering to a lithium battery can damage it or cause a short. A simple 18650 holder costs pennies and makes replacement easy. If you must solder directly, work quickly and use a low-temperature iron (350°F max).
**Step 2: Wire the LED and current-limiting resistor.** The LED has a positive (anode, longer leg) and negative (cathode, shorter leg). Solder the resistor to the anode, then connect a wire from the resistor's free end to the TP4056 module's OUT+ pad. Connect the cathode directly to OUT- on the module. This gives you a constant current source. Want more brightness? You can parallel two LEDs, but each needs its own resistor. Test with your multimeter before soldering—you should see about 3.2V across the LED when powered.
**Step 3: Add the switch and auto-on circuit.** For manual control, wire the switch between the LED's positive wire and the OUT+ terminal. For automatic operation (light turns on when power fails), you need a relay or a MOSFET. A simple N-channel MOSFET (like IRF520) can be triggered by the incoming AC power. When power is present, the MOSFET gate is high, keeping the LED off. When power drops, the gate goes low, and the LED lights up. This is the same circuit used in commercial emergency lamps. I've included a wiring diagram in the video description, but the basic idea is: connect the gate to the input power through a 10k resistor, drain to the LED negative, source to ground.
**Step 4: Mount everything in the enclosure.** Drill holes for the switch, LED, and USB charging port. Use hot glue to secure the battery holder and charging module. Attach the LED to the heatsink with thermal paste, then glue the heatsink to the enclosure wall. Make sure there's ventilation—these LEDs get warm. Run the wires neatly and avoid pinching them when closing the box. I like to use a small zip tie to bundle wires.
**Step 5: Test and calibrate.** Before sealing the box, plug in the USB charger. The TP4056's red LED should light up, indicating charging. After a few minutes, check the battery voltage with your multimeter—it should be around 4.2V when full. Then unplug and flip the switch. The LED should be blindingly bright. If it's dim, check your resistor value—you might need a lower resistance for more current.
Safety First
Let's get serious for a moment. Lithium-ion batteries are powerful and dangerous if mishandled. Never short-circuit the battery terminals—that can cause a fire. Always use a protected cell or a protection circuit (the TP4056 module includes one, but double-check). When soldering, work in a well-ventilated area and wear safety glasses—solder splatter is real. If you're unsure about polarity, use your multimeter to confirm before connecting power. A reversed battery can destroy the charging module and potentially cause a fire.
Also, don't leave the charging module plugged in unattended for long periods. While the TP4056 has built-in protection, it's best practice to unplug once fully charged. And never use a damaged or swollen battery—replace it immediately. If you smell smoke or see the battery getting hot, disconnect power and move the project to a non-flammable surface (concrete or metal).
Troubleshooting
Even experienced builders hit snags. Here are common issues and how to fix them:
- **LED doesn't light up**: Check all solder joints with a multimeter. Measure voltage across the LED—should be ~3.2V. If it's 0V, trace back to the battery and switch. Also, make sure the switch is in the "on" position.
- **LED is very dim**: Your resistor might be too high. For a 3W LED at 700mA, you need about 1 ohm. Use Ohm's law: R = (Vsupply - Vled) / I. For a 3.7V battery and 3.2V LED at 0.7A, R = (3.7 - 3.2) / 0.7 = 0.71 ohms. Use a 1-ohm resistor for safety.
- **Battery doesn't charge**: Check the TP4056 module's input voltage. It needs 5V from USB. If the red LED doesn't light, the module might be dead or the battery is fully charged (green LED). Also, verify polarity—the module's B+ and B- must match the battery.
- **Auto-on feature doesn't work**: If you used the MOSFET circuit, check the gate voltage. When AC power is present, the gate should be high (above 3V). If not, your 10k resistor might be wrong or the MOSFET is damaged.
- **Battery runs out too fast**: Your LED might be drawing too much current. Measure the current with a multimeter in series. For a 2000mAh battery with a 700mA LED, you should get about 2.8 hours of runtime. If it's less, your battery might be old or damaged.
The Result
After about two hours of careful soldering and assembly, you'll have a compact, rechargeable emergency lamp that fits in the palm of your hand. The one I built for this guide runs for 3.5 hours on a full charge with a 3W LED—plenty of time to cook dinner, read a book, or finish a project. It charges fully in about 2 hours via any USB port. The auto-on feature works flawlessly: when the power goes out, the light comes on instantly. I've tested it in the garage, during camping trips, and even as a reading light.
If I were to do it again, I'd add a second LED for more light and a dimmer switch for adjustable brightness. But for a first build, this is solid. The total cost was $18, and I used parts I had lying around. The satisfaction of building your own backup light is immense—you know exactly how it works and can repair it yourself. Plus, it's a great conversation starter when guests ask, "Where'd you get that cool lamp?"
Now go build one. You'll thank yourself the next time the lights go out.






