It’s harder to replace your phone’s lithium ion battery than it is to treat it right in the first place. Many smartphones don’t provide easy user access to their batteries. That includes all iPhone and many flagship Android phones from brands such as Samsung. Official battery replacements can be expensive or inconvenient (try getting an official battery replacement at an Apple Store this year). There are also environmental concerns. Smartphones are, frankly, an environmental disaster and extending the lifespan of your phone battery helps mitigate that.

Here are some things you can do to preserve and extend the lifespan of your phone battery. By battery lifespan I mean how many years and months your battery will last before it needs to be replaced. In contrast, battery life refers to how many hours or days your phone will last on a single charge.

A generic cell phone with low battery

1. Avoid extremes of heat and cold. If your phone gets very hot or cold it can strain the battery and shorten its lifespan. Leaving it in your car would probably be the worst culprit, if it’s hot and sunny outside or below freezing in winter.

2. Avoid fast charging.

Charging your phone quickly stresses the battery. Unless you really need it, avoid using fast charging.

In fact, the slower you charge your battery the better, so if you don’t mind slow charging overnight, go for it. Charging your phone from your computer as well as certain smart plugs can limit the current going into your phone, slowing its charge rate. Some external battery packs might slow the speed of charging, but I’m not sure about that.

4. Avoid draining your phone battery all the way to 0% or charging it all the way to 100%.

Older types of rechargeable batteries had ‘battery memory’. If you didn’t charge them to full and discharge them to zero battery they ‘remembered’ and reduced their useful range. It was better for their lifespan if you always drained and charged the battery completely.

Newer phone batteries work in a different way. It stresses the battery to drain it completely or charge it completely. Phone batteries are happiest if you keep them above 20% capacity and below 90%. To be extremely precise, they’re happiest around 50% capacity

Short charges are probably fine, by the way, so if you’re the sort of person that finds yourself frequently topping up your phone for quick charges, that’s fine for your battery.

Paying a lot of attention this one may be too much micromanagement. But when I owned my first smartphone I thought battery memory applied so I generally drained it low and charged it to 100%. Now that I know more about how the battery works, I usually plug it in before it gets below 20% and unplug it before completely charged if I think of it.

5. Choose a dark theme.

My phone, the Galaxy S7, has an OLED screen. To display black it doesn’t block the backlight with a pixel like some iPhones and many other types of LCD screens. Instead, it doesn’t display anything at all. The pixels displaying black just don’t turn on. This makes the contrast between black and colour very sharp and beautiful. It also means that displaying black on the screen uses no energy, and darker colours use less energy than bright colours like white. Choosing a dark theme for your phone, if it has an OLED or AMOLED screen, can save energy. If your screen does not have an OLED screen — and this includes all iPhones before the iPhone X — a dark theme won’t make a difference .

I found a dark theme I like in the Samsung store, and there are some excellent free icon pack apps for Android out there that focus on darker-themed icons. I use Cygnus Dark, Mellow Dark, Moonrise Icon Pack, and Moonshine. I use the Nova Launcher App to customize the appearance of app icons and often remove the name of the app if it’s clear enough from the icon what it is. That removes white space off of the screen, and I also think it looks nice and is less distracting.

Some people find a darker theme is easier on the eyes in terms of preventing eye strain, and less light overall may mean less blue light, which can affect sleep patterns.

Many apps include a dark theme in their settings. For example, I have Google Books set to a dark theme, where the virtual ‘page’ is black instead of white and the letters are white. Most of the pixels display black (are turned off) and use no energy.

I’m less familiar with customization and dark themes for iPhones. My understanding is that iPhones are somewhat harder to personalize. So far, though, only the iPhone X series have OLED screens so they are the only iPhones that would see energy savings from a dark theme.