Pocket Lint

If you tend to carry your iPhone 5, 5c, or 5s in your pocket there is a good chance that pocket lint will accumulate in the Lightning connector.  This will tend to cause a poor connection with the Lightning cable and make for erratic charging.  The best way to fix this is to take a plastic or wood toothpick and clean out the connector.  Never use the end of a paper clip because a conductive material like metal could cause electronic damage.  This was the remedy for my poor iPhone 5 charging.  Sure enough there was lint in the connector.  Now that it's clean I am getting more reliable charges.