If the iPhone battery wont charge there are some solutions that we can do to restore it back to normal. Actually can not charge the battery is a software problem rather than hardware . Because one or the other settings can make our iPhone error so be careful you better learn before messing with iPhone
The first solution:
Plug charger into electricity as usual, leave it few hours to charging, then press the power button (on / off) on the iPhone and the battery sign will appear only by a thin red line. even iPhone does not charge let it until off (blank screen). Once off, hold the power button and home button about 8 seconds, iPhone screen will pop up the question “ want to turn off iPhone”. Answer Yes. Wait a few seconds while your iPhone is in off state. Unplug the charger on the iPhone and connect again with the iPhone. After a few seconds then the iPhone will reboot and the Apple logo will appear as usual and the Springboard menu will appear again.
The second solution:
This second solution restore the iPhone again but in a state totally off and the iPhone will we connect with the computer. Press the power button until the iPhone off, about 8 seconds, then open iTunes on your computer. While pressing the home button connect the iPhone to your computer and iTunes will read back the iPhone wait for 6 seconds and we can start restore iPhone (if your iphone not factory unlock it will locked after this process)
Third solution: (need 2 people)
Turn on iTunes, prepare the cable to connect your iPhone and computer, then press the power button and home button until your iPhone is completely off (the cable is still connected with the computer). Connect the iPhone to the computer and immediately release the power button with still pressing home button, iTunes will open and read prepare our iPhone firmware and restore
Solution 4: iTunes does not read our iPhone
Try to go to the apple.com site and download the latest iTunes then install new downloaded iTunes then connect with you iPhone and try to restore the iPhone.