Over the years, users of portable consumer electronics have just come to accept that battery life gets worse over time. But it doesn’t have to: Gbatteries, which is in the current batch of Y Combinator companies, has come up with a new technology called BatteryOS that provides better performance without battery-life degradation.

The first example of this technology is BatteryBox, a rechargeable Lithium-ion battery pack that carries enough power — 50 Whr — to run a MacBook Air for 12 hours, a MacBook Pro for six hours, or to charge eight iPhones.

About the size of the typical MacBook power adaptor and weighing less than 9 ounces, BatteryBox packs a punch. In addition to a MagSafe2 cord for charging current-generation MacBooks and MacBook Airs, it also has a port to connect any other devices that charge via USB.

The BatteryBox itself is charged via MicroUSB, and takes about four-and-a-half hours to reach an 80 percent charge or nine hours for 100 percent charge on a 1A power supply. Cut those times in half with a 2A power supply.

The device itself is available for pre-order for $139 now, and is expected to ship to customers this fall.

But this isn’t just about a portable battery backup for MacBooks and other gadgets — it’s about a new battery management system designed to reduce the degradation of batteries over time. That technology is being embedded into the BatteryBox itself, which will withstand 3,000 full charge and discharge cycles and still have 96 percent of its capacity available after five years.

Batteries are typically charged and discharged through a constant stream of power, which causes problems like SEI layer formation that causes the battery to degrade over time. The BatteryOS system, by contrast, takes an active role in managing what’s happening inside a Li-ion battery, which not only lengthens the life of the battery, but also gives it the ability to store 10 percent to 40 percent more power.

While BatteryBox is the first implementation of the BatteryOS technology, the company believes it’s really just a proof of concept for a much bigger idea — improving the battery life of all our devices. That’s because the same concepts that BatteryBox for losing its battery life over time can be applied to any number of things, from laptops to electric cars.

“Most devices undercharge batteries because they last longer,” according to co-founder Tim Sherstyuk. He gave the example of the Chevy Volt, which only charges its battery to 50 percent capacity at the start to reduce degradation over time. But BatteryOS could get better performance out of those batteries and they would last longer.

“With the same battery, we could charge to a full 100 percent and it won’t degrade,” he said.

It’ll take some time for Gbatteries to get its technology embedded with third-party OEMs, but in the meantime gadget users can take advantage of it with BatteryBox.