You most likely have poor grounding to or from the breaker box in your home.
The first thing I would do is get myself one of these nifty devices. I generally dislike the cheap tester lights as they don't tell you very much. It is called a Voltimeter and it will be able to tell you if a current is passing and how much voltage exists to your ground.
![enter image description here](https://i.stack.imgur.com/X4kWM.jpg)
It has many settings, for testing your typical 120v AC home outlet you can set it to test AC voltage at the ACV 200 setting. Test hot to neutral first and make sure that you have 115-130 volts on the meter display. Next test hot to ground and make sure that you get the same reading.
If you get a lower number than this or if it remains close to zero then your outlet has not been properly grounded.
Test the other outlets in the home and they register the same then it could be a problem with your breaker box not being properly grounded. It could also be if your house is older that the original outlet boxes were never grounded to the breaker, and someone had just installed three pronged outlets throughout the house without bothering to ground the outlet boxes.
It sounds like the two black wire with the pigtail are the incoming hot and a branch hot to another location, such as the outlet. The other black attached to the switch is probably the switched hot that goes to the fixture being controlled.
You can verify this by turning the switch to off, making sure all the wires and terminals are clear and not touching anything else metal, and then turning on the breaker. Using the non-contact tester, carefully check the wires. The paired blacks should read hot, but the switched black should not.
If this is what you have, wiring the new switch is pretty straightforward. Turn the breaker off again. Confirm no wires are now hot. The new switch is basically connected the same way as the old, but with a neutral wire and ground wire added.
- The hot pigtail is connected to the line terminal.
- The switched black wire is connected to the load terminal.
- A pigtail (white) is added to the bundle of neutral wires and connected to the neutral terminal
- A pigtail (bare) is added to the bundle of ground wires and connected to the ground terminal.
The traveler terminal is not used (and it looks like it is covered anyway).
Use wire nuts, and if you like, tape over them for extra safety. You also could put a wrap of tape around the z-switch covering the terminals. Carefully insert the wires back in the box. Screw the switch into the box. Turn the power back on.
While most dumb switches do not need a neutral connection, many smart switches, such as the z-switch, do. Now all switches have a separate ground connection, although many in the past did not.
Best Answer
Switch off all the breakers, then test again.
Turn on the breakers one by one and that way you will locate the one causing the issue.
Many times I have found that what is on the label is not true.
Always test with a multimeter before using fingers...