CT Clamp for ESP

You might also want to look at IoTaWatt. It’s open source, and I think they are using 8266 and talking about migrating to ESP32’s. It’s not esphome, but it’s already got all the work done to do the calculations and monitoring and history accumulation.

Their hardware is really nice also but since it’s open source you could use it to roll your own.