The Shelly EM Mini Gen4 (S4EM-001PXCEU16) is a compact single-phase smart energy meter (29 x 34 x 16 mm) that measures the consumption of one circuit or appliance up to 16 A / 3840 W at 240 V~. It has no relay — it measures only and cannot switch the load. The measured current flows directly through the device, so no current transformer is needed.
TapHome reads the device over its local HTTP API on the Wi-Fi network every second — no cloud connection is required. The device also supports Zigbee and Matter, but this template needs it connected to Wi-Fi. For the previous-generation power monitor, see Shelly PM Mini Gen3.
Hardware connection
The device fits into an in-wall box or a wall console and is powered from the measured line (110–240 V~, below 1 W).
| Terminal | Function |
|---|---|
| L | Live wire (110–240 V~) |
| N | Neutral wire |
| O | Output to the measured load — two terminals, bridged internally |
- Connect the live wire to the L terminal.
- Connect the neutral wire to the N terminal.
- Connect the load to one of the O terminals and to the neutral wire. The whole load current passes through the device, which is how it is measured.
Strip the wires to 6–7 mm, tighten the screw terminals to max. 0.4 Nm and do not put more than one wire into a single terminal.
Installation on the power grid must be done by a qualified electrician. Switch the circuit breakers off and check with a suitable tester that the wires are dead before connecting. The device and the connected load must be protected by a circuit breaker according to EN 60898-1 — characteristic B or C, max. 16 A rated current. Do not connect a load above 16 A. The device is for indoor use only.
Configuration
Connecting to Wi-Fi
The template needs the device connected to a 2.4 GHz Wi-Fi network.
- Press and hold the button on the device for 5 seconds. This turns on its access point and Bluetooth; the access point appears as
ShellyEMMiniG4-XXXXXXXX. - Add the device to your Wi-Fi network in one of two ways:
- in the Shelly Smart Control mobile app, add a new device and follow the app, or
- connect a phone or computer to the
ShellyEMMiniG4-XXXXXXXXnetwork, openhttp://192.168.33.1in a browser and enter your Wi-Fi name and password in the device web interface.
- After the device joins the network, the manufacturer recommends turning off or password-protecting the device access point.
Holding the button for 10 seconds performs a factory reset — release it at 5 seconds when you only want to enable the access point.
The device ships with Matter firmware by default. Pressing the button five times switches it to Zigbee mode, where its access point is off by default. If the device was switched to Zigbee, return it to Wi-Fi operation as described in the manufacturer’s knowledge base before using this template.
Network address and reachability
To check that the device is reachable, open the following address in a browser on a computer in the same network as the TapHome Core:
| |
If the browser shows a JSON response with the device model and MAC address, the device is reachable.
Authentication and firmware
Password protection (authentication) must be turned off on the Shelly device. The template connects without credentials and cannot read a device that asks for a password. Check this in the device web interface or in the Shelly Smart Control app.
Keep the device firmware up to date — updates are available in the device web interface and in the Shelly Smart Control app.
Import in TapHome
Import the template and enter the IP address of your device. The template comes with the address 10.10.10.2 filled in — replace it with the address of your Shelly. The template connects to the device on HTTP port 80.
Device capabilities
The template creates one read-only device. TapHome reads the Shelly every second.
| Device | Name in template | Unit | What it shows |
|---|---|---|---|
| Electricity meter | Elektromer | kWh, kW | Total consumption and current power demand of the measured circuit |
Service attributes
The Electricity meter also shows these values as service attributes, each as text together with its unit:
| Value | Name in template | Unit |
|---|---|---|
| Total consumption | Celková spotreba | kWh |
| Returned energy | Vrátená energia | kWh |
| Voltage | Elektrické napätie | V |
| Current | Elektrický prúd | A |
| Active power | Aktívny výkon | W |
| Frequency | Frekvencia | Hz |
The module shows the connection details of the device as service attributes:
| Value | Name in template | What it shows |
|---|---|---|
| Wi-Fi signal strength | Rssi | Signal strength in dB |
| Uptime | UpTime | Time since the last device restart, in days |
| Wi-Fi network | Wifi | Name of the Wi-Fi network the device is connected to |
| IP address | IP | Current IP address of the device |
When the device reports that it needs a restart (for example after a firmware update or a settings change), the module shows the warning “Vyžadovaný reštart zariadenia” (device restart required). Restart the Shelly in the device web interface or in the Shelly Smart Control app.
Energy metering
The Electricity meter shows the total consumption in kWh and the current power demand in kW. The same power is also shown in watts in the Active power service attribute.
The device measures energy in both directions. Returned energy is the energy delivered back to the grid through the measured circuit — for example from a photovoltaic system — and is counted separately from consumption.
Troubleshooting
Device is offline or shows an error
- Check that the TapHome Core and the Shelly are in the same network (same VLAN / subnet), or that the router allows HTTP traffic between them.
- Check that the IP address in the template matches the current address of the device — the address may have changed.
- Open
http://<device-ip>/rpc/Shelly.GetDeviceInfoin a browser on the same network as the Core. A JSON response means the device is reachable. - If the browser asks for a user name and password, authentication is enabled on the Shelly — turn it off.
- Check that the device is in Wi-Fi operation and not in Zigbee mode.
- Check the Wi-Fi signal strength in the Rssi service attribute of the module, in the Shelly Smart Control app or in the device web interface — a weak signal causes intermittent outages.
Values show no reading
- If the device answers in the browser but the values stay empty, update the device firmware and import the latest version of the template.
- If power and current stay at zero, check that the load is connected through the O terminals and that the circuit is switched on — the device measures only the current that flows through it.
