Mains AC: non-invasive measuring

Mains AC: non-invasive measuring @ OpenEnergyMonitor

This method of measuring mains AC electrical energy use is quite nice, it doesn’t require any breaking of the mains wire, which makes it much safer, you just clip-on to the wire a sensor called a current transformer (CT) that measures the current flowing through either the live or neutral mains wire. It does this by measuring the magnetic field that surrounds the wire, created by the current. The simplicity of just clipping on the sensor means that it can be used to measure the electrical energy used by the whole house. It is the method used by many commercial devices that you can buy.

I don’t have much knowledge of how the commercial devices work apart from the use of the CT sensor, I couldn’t find much information on them and so the following is what I have managed to get to work in quite an experimental way. The results seem promising and useful, there are probably better more accurate ways of doing it and so hopefully it will improve over time but this is how far I have got so far.

Read more on the project page!

Adafruit publishes a wide range of writing and video content, including interviews and reporting on the maker market and the wider technology world. Our standards page is intended as a guide to best practices that Adafruit uses, as well as an outline of the ethical standards Adafruit aspires to. While Adafruit is not an independent journalistic institution, Adafruit strives to be a fair, informative, and positive voice within the community – check it out here:

Join Adafruit on Mastodon

Adafruit is on Mastodon, join in!

Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on, jump into CircuitPython to learn Python and hardware together, TinyGO, or even use the Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for CircuitPython, MakeCode, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.

Have an amazing project to share? The Electronics Show and Tell is every Wednesday at 7pm ET! To join, head over to YouTube and check out the show’s live chat – we’ll post the link there.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Join over 36,000+ makers on Adafruit’s Discord channels and be part of the community!

CircuitPython – The easiest way to program microcontrollers –

Maker Business — “Packaging” chips in the US

Wearables — Enclosures help fight body humidity in costumes

Electronics — Transformers: More than meets the eye!

Python for Microcontrollers — Python on Microcontrollers Newsletter: Silicon Labs introduces CircuitPython support, and more! #CircuitPython #Python #micropython @ThePSF @Raspberry_Pi

Adafruit IoT Monthly — Guardian Robot, Weather-wise Umbrella Stand, and more!

Microsoft MakeCode — MakeCode Thank You!

EYE on NPI — Maxim’s Himalaya uSLIC Step-Down Power Module #EyeOnNPI @maximintegrated @digikey

New Products – Adafruit Industries – Makers, hackers, artists, designers and engineers! — #NewProds 7/19/23 Feat. Adafruit Matrix Portal S3 CircuitPython Powered Internet Display!

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at !


  1. Thank you for the nice idea for my study. Then i found this ..

  2. All the major makers of ICs to do energy measurement (Microchip, Atmel, TI, Analog Devices, Teridian, etc.) have design notes and/or app notes which contain a ton of information about how to do a really good job with this.

    Have to tell ya that you’re not going to get very accurate results with an Arduino and CTs. You need pretty good ADCs (think ~18-19 bits) and the ability to do some significant math quickly. CTs aren’t really that accurate (for absolute measurement) without compensating for the phase changes due to the fact that they’re inductive.

    CTs *do* have some huge advantages in a lot of applications, but they (like Hall effect sensors) are not the best for accurate measurement. I’d be surprised if you could get much better than +/- 25% accurate with just an Arduino across a wide variety of loads given the limitations of all of the pieces.

    However if +/- 25-35% is good enough and you don’t want to futz with AC directly, then it’s a really good start.

  3. It is really a nice idea.

    The article pointed by Dajp is very nice too. Thank you.

  4. Possibly previously linked by adafruit – but covers a similar project

  5. CTs are available in different accuracy ratings, among the most accurate being “revenue grade”, typically being accurate to +/- 0.1%, and are generally used in either revenue metering applications (i.e. subtenant metering), power quality applications (i.e. monitoring utility power for voltage sag/swells or transients) or protection applications (i.e. monitoring differential current across two ends of a feeder cable to determine if there is a ground fault).

    CTs are available in a few configurations – split core, solid core and wrap-around. Solid core CTs are donut-shaped and require the wire that you want to monitor to be disconnected and fed through the center of the CT. Split-core CTs “break” open (like those ferrite beads used on power cables) and can be put on a “live” wire without interrupting the load. Wrap around CTs are generally used in temporary applications, like monitoring generator output during load bank testing.

    CTs output different types of signals, depending on type, usually either current (0-5A) or voltage (0-10V). CTs are specified by the maximum current that they can measure and their output at that range, i.e. 1000:5 (1000Amps gives a 5Amp signal, so just multiply your secondary signal by 200 to get your primary current).

    Be aware of one big saftey issue when working with CTs. If the CT is around a wire with current flowing through it, and the secondary side of the CT is not grounded, huge voltages can get induced inside the CT and it can damage te CT and possibly explode. Always make sure to ground one of the CT output wires when it’s under load.

    Anyway, the company I work for makes high-end power quality meters and other monitoring equipment/software. I design/commission electrical monitoring systems for data centers (from the 138kV utility voltage, through the 13kV generators and primary distribution down to the 110V RPP feeds each server rack).

  6. This is indeed not a method that shows how electrical energy works, but it’s quite nice as well and you can learn how a battery, dynamo and electrons works…

    Check it out:

  7. Thanks for posting this up on your blog! and thanks for all the information on CT’s and accuracy.

    Id like to add that the main thing that I think I’ve managed to do with this method is find a way to calculate an estimate for real power and power factor without measuring the voltage waveform by “synthesising” a voltage waveform from the current waveform measured. The synthesised voltage waveform amplitude is set manually by entering the typical rms voltage of your area.

    Ive posted up the results of a comparison between this method using the CT and arduino vs a cheap commercial plug in power meter here:

    A large source of inaccuracy is due to the manually set rms Voltage due to variation in rms Voltage in the grid, but then commercial meters like the efergy energy monitor require a manually entered rms Voltage value. With this project Im aiming at an accuracy comparable to commercial domestic monitors like the efergy monitor, I actually still need to do that comparison but the comparison with the plug in meter which should be more accurate than the efergy looks good.

    It would be great to hear any of your thoughts on the results and the voltage “synthesis” method of estimating real power and power factor.


Sorry, the comment form is closed at this time.