Battery failing to charge at engine idle

My battery died on me twice in the past week. The first time it was able to be jumped by another car. The second time it needed to be jumped by a tow.



I took it straight to a mechanic who claimed it was a bad battery. But I took it to a second mechanic to get the battery replaced under warranty. The second mechanic ran a test and noticed that when he revved the engine, the battery would charge. It wasn’t charging when the engine was idling.



Obviously he said it was a charging issue.



I then risked the car dying and made a four hour road trip home. I’ve managed to keep the battery charged enough to keep starting the car.



My question is, what’s the problem? It seems like an issue with the wiring or the alternator. And how can I determine the problem and/or fix it myself.

A loose/bad belt or tensioner would be step 1 to look at. Many parts stores will also do a free battery check.

Many parts stores will also do a free battery check. And charging system.

Likely a bad diode in the alternator.
Get the alternator tested.

What year is your vehicle? If you have a digital multimeter and know how to use it, you can do some testing yourself? Some makes and models can set trouble codes for the charging system. Not sure about yours? Everybody have a good day.