I have some iPhones which are connected via USB to a computer 24/7.

This set-up drastically reduces the battery life-time: The integrated battery is swelling every 1-2 years in a way that the iPhone nearly disassembles itself (the device has a gap in the middle of more than 5mm so that you can right look into the device and the display is a bit "curvy").

As the devices nearly constantly are powered via USB the battery I don't care if the battery is charged 50% or 100%. Is there a possibility to limit the maximum charge or is it possible to disable charging on a jailbroken device?

Note other answers like "don't charge the device the whole night" are useless to me as the phones have to be connected via USB 24/7 because the devices are accessed via SSH over USB. And answers that indicate that there is no risk in charging a device 24/7 are obviously wrong as I have multiple devices that continuously get a swelling battery after a certain time if they are connected via USB 24/7.

  • 1
    Possible duplicate of Does charging to 100% damage an iPhone battery
    – IconDaemon
    Sep 25, 2019 at 13:58
  • @IconDaemon I disagree, the linked qeustion is not a duplicate. This question is about if it is harmful, but I know that it is harmful by example. Additionally the answers like "don't charge the device the whole night" are useless to me as the phones have to be connected via USB 24/7 because the devices are accessed via SSH over USB.
    – Robert
    Sep 25, 2019 at 14:09
  • iOS 13.1 reduces the time your iPhone spends fully charged to slow the rate of battery ageing. It does this by optimising the battery charging process, so that may be a good starting point for you.
    – Monomeeth
    Sep 25, 2019 at 22:18

1 Answer 1


There's really no option in the iPhone to limit it to charging the battery to 50%, or temporarily disable charging.

However, I suggest that you turn the problem around and look at it differently. Namely just stop supplying power to the phone, when you do not want it to charge. You can leave the cable plugged in and have data transfers continually, but just don't supply the +5V for charging.

This can be done by plugging the iPhone into a hub that supports per-port power control and then plugging the hub into a computer, where you can use uhubctl to turn on/off ports as you like:


  • An interesting idea, however in reality it is not easy to implements as power enabling/disabling requires knowledge on how much power is left in the battery - as you don't want to let the phone run out of power (as this would kill the jailbroken state). The best way would be if uhubctl could run on the USB client (in this case the iPhone), but I assume that this is not the way uhubctl works.
    – Robert
    Sep 25, 2019 at 14:32
  • I just read that on iOS 13 there is a function that performs "intelligent charging": By charging stops at 80% and continues to 100% based on when you need your device (as the device has learned it). Therefore there seems to be a software API to control the charging process. Unfortunately I can't upgrade to iOS 13 as it misses a jailbreak until now. But for stock devices this sound promising.
    – Robert
    Sep 25, 2019 at 15:42
  • Regarding running from the iPhone - you can definitely control it from the iPhone. You indicated that you use these phones for SSHing, so you could just let the iPhone ssh into for example a Linux box controlling the power and use uhubctl to turn charging off.
    – jksoegaard
    Sep 25, 2019 at 16:21
  • Regarding Intelligent Charging - this will charge your device to 100% eventually. The idea is that if you plug your device in for charging overnight every day, the device will charge to 80% and leave it there for a while, then resume charging so that it gets to 100% at approximately the time where you wake up. This doesn't mean that a public API exists to control charging (but this probably doesn't concern you as you're jailbreaking).
    – jksoegaard
    Sep 25, 2019 at 16:23
  • We will have to see how this mechanism works with devices that are 24/7 connected. As I am targeting jailbroken devices - a missing public API is nothing that makes me worry. May be the battery charger functionality is already available on iOS 12 but nobody has discovered it...
    – Robert
    Sep 25, 2019 at 17:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .