Could be the phone, the port, or the charging cable
If you are using a cigarette lighter charger, then it might be going bad. If you have a USB adaper in the lighter socket and using a USB cable try the following.
Try turning off the phone then connect it to the charging cable. If you do not get static with the phone off, then it's probably something with the phone or a running app?
If that does not stop the static, then replace the cable....preferably with a shielded data/charger cable. If that does not help, then you probably have a bad or loose connection in the USB port.
....Rich