This is a problem I had recently with my iPhone 5, and a quick glance at the Apple forum tells me that I am far from alone. Putting in the Lightning cable and attaching a charging plug leads to a symphony of buzzing, but very little charging. It takes constant tweaking and balancing to get any charge into my iPhone. It just feels like the cable doesn't work. So what gives?

In this article I outline what you can do if your iPhone or iPad just won't charge. A temporary fix I have found, the official advice from Apple, and my best advice on what to do if it just won't fix. Here's what to do if your iPhone or iPad won't charge. (See also: How to charge your iPhone (or iPad) faster.)

Read: Complete guide to ports on Macs, iPhones and iPads

Can't charge iPhone: Lightning port isn't working - temporary fix

File this under very short-term solutions. But I have found that blowing into the Lightning port to remove dust and fluff, can have a positive impact. And then gently balancing the phone on the connector to charge. You have to be careful with the latter, because the charging cable is prone to snapping off when two much pressure is placed on it. But it does at least feel that it helps to place enough pressure on to the Lightning connector so that it is forced into the phone helps. Weirdly I have found that using an old 30-pin iPhone cable with a Lightning adaptor works better than a standard Lightning cable.

This is not official advice, just my experience. And as with all hardware issues, it is unlikely to improve with time. You really need to get this problem solved.

Here's how to reset and restore a frozen iPhone | How to send feedback to Apple when its products go wrong, and why you should

Can't charge iPhone: Lightning port isn't working - troubleshooting tips

Here is the official advice from Apple. First, unplug your iPad or iPhone. Then look at the connector at the bottom of your device and make sure it's free of debris. I do this with a quick blow. Likely the Apple experts would suggest using a compressed air blower.

This won't be the problem, but it is always worth trying: if you're using a USB power adapter, make sure it's plugged in all the way and the power outlet is working. If you're connecting to a computer, make sure that it is on (and that it can charge your device). I know you have already tried all of these things, but you never know.

Similarly, where possible try a different cable, power adapter, or USB port. Charging cables do break easily, and there is always a chance that it is the cable or the charger. Testing each component part is just sensible. We talk about how to test each component of the charging system, how to repair the cable or power adapter if they are faulty, and whether it's safe (or even worth the effort) to do so, in a separate article: How to fix a broken iPhone or iPad or iPod charger, and when you're safer just buying a new one.

If everything seems to be working, Apple's next advice is to reconnect your device and wait for 30 minutes. Personally, I think this is nonsense, but it is worth taking a belt and braces approach. If your device still doesn't charge, Apple suggests you try to restart it while it's connected to power. If you can't restart, reset your device. You may then see an alert when you plug in your device, such as "This accessory is not supported by this device". In which case you know the problem is the charging equipment.

Frankly, you need to get in touch with Apple support.

Read next: 33 tips to help boost iPhone battery life | How to back up an iPhone | How to fix an iPhone with a broken off button

Can't charge iPhone: Lightning port isn't working - get Apple to fix it

Trouble is, most of the initial support will follow the steps outlined above. Very quickly when you go into the - helpful - Apple online support program, you will be asked to send or take in your iPhone or iPad for a service. This is all to the good, but out of warranty we have heard of people being charged £200 for a repair for this problem.

Ideally at this stage your insurance will kick in. If you have bespoke phone insurance, or even a good quality of home and contents insurance, you may be able to claim the repair through your insurance. If you are on a contract, it may be that your network provider will foot the cost of repair or replacement, even if it means signing up for a longer period. If not, you need to balance the cost of repair against the cost of a new phone. This isn't good news, but at £200 for repair you are probably better off buying a handset.

See also: Charging safety: Are cheap, non-Apple iPhone chargers safe? | iPhone 6 reviewiPhone 6 Plus review | iPhone 7 rumours