Home Assistant integration

Two ways to connect your Pylon-Monitor — both are built into the firmware: no HACS, no custom integration, no add-on to install on the device side. Pick MQTT auto-discovery (zero YAML) and you're done in seconds, or paste 30 lines of REST YAML if you don't run a broker. Either way, plug & play.

Choose your integration

Open the device Settings page (http://<DEVICE-IP>/settings). Both options are configured from there. Pick one — they are independent and can be enabled/disabled separately.

Option 2

REST API polling

No broker required. Home Assistant polls the built-in JSON endpoint /api.json directly. Paste the YAML once — the device's Settings page actually generates it for you, with your IP already filled in.

What you do: paste YAML into configuration.yaml
What HA sees: 6 sensors
Update: pull-based (every 30 s)
Configure Option 2 ↓
Use your own device IP. The examples below show <DEVICE-IP> as a placeholder — replace it with the IP shown on the TFT screen. To keep the integration stable, either set a DHCP reservation in your router (recommended) or fill in the Static IP section on the device Settings page.

Option 1 — MQTT auto-discovery

Recommended if you already use the Mosquitto / MQTT broker add-on in Home Assistant. Once the broker connection is set, the device publishes Home Assistant discovery configs to standard homeassistant/sensor/… topics, and sensors appear in Settings → Devices & Services → MQTT within a few seconds — grouped under a single device named Pylon-Monitor.com.

What you fill in on the device

On the device Settings page, open the MQTT Home Assistant card and fill these four fields exactly as the firmware expects them:

Server IP<broker-ip>
Port1883
Username<mqtt-user>
Password••••••••

Save. The Pylon-Monitor's dashboard MQTT row turns blue (Connected) within ~5 seconds. To disable MQTT, simply clear the four fields and save.

Topics the firmware publishes

The device hostname (default pylon-monitor) is used as the topic prefix and discovery node id. Replace it below with the hostname you chose.

SensorDiscovery config topicUnit / class
SOChomeassistant/sensor/pylon-monitor/soc/config% · battery
Voltagehomeassistant/sensor/pylon-monitor/voltage/configV · voltage
Powerhomeassistant/sensor/pylon-monitor/power/configW · power
SOHhomeassistant/sensor/pylon-monitor/soh/config% · mdi:battery-heart-variant

All four sensors share a single state topic from which they pull their values:

pylon-monitor/state

The payload published a few times per minute looks like this:

{
  "soc": 94,
  "voltage": 48.62,
  "power": -350.1,
  "soh": 96,
  "temp": 23.4
}

The temp field (battery base temperature) is published in every state message but isn't exposed via auto-discovery in the current firmware. If you need it in HA via MQTT, add a manual mqtt sensor: entry pointing at the same state topic and value_template {{ value_json.temp }}.

Tip — Mosquitto add-on credentials. Create a dedicated MQTT user in Home Assistant → Settings → People & Add-ons (or in the Mosquitto config), then use those credentials here. Don't reuse your HA login.

Option 2 — REST API polling

No MQTT broker required. Home Assistant's built-in rest platform polls the device every 30 seconds and creates 6 sensors. The YAML block below is the exact one the firmware itself generates inside the Settings page (with your current IP pre-filled) — copy-paste it from there for zero typing, or use the version below.

The JSON the device returns

GET http://<DEVICE-IP>/api.json

{
  "system": "pylon-monitor",
  "firmware": "v1.1",
  "summary": {
    "soc": 94,
    "soh": 96,
    "voltage": 48.62,
    "current": -7.20,
    "power": -350.10,
    "state": "Discharge"
  }
}

Paste this in configuration.yaml

rest:
  - resource: http://<DEVICE-IP>/api.json
    scan_interval: 30
    sensor:
      - name: "Pylontech SOC"
        unique_id: pylontech_soc
        value_template: "{{ value_json.summary.soc }}"
        unit_of_measurement: "%"
        device_class: battery
        state_class: measurement
      - name: "Pylontech SOH"
        unique_id: pylontech_soh
        value_template: "{{ value_json.summary.soh }}"
        unit_of_measurement: "%"
        state_class: measurement
      - name: "Pylontech Voltage"
        unique_id: pylontech_voltage
        value_template: "{{ value_json.summary.voltage }}"
        unit_of_measurement: "V"
        device_class: voltage
        state_class: measurement
      - name: "Pylontech Current"
        unique_id: pylontech_current
        value_template: "{{ value_json.summary.current }}"
        unit_of_measurement: "A"
        device_class: current
        state_class: measurement
      - name: "Pylontech Power"
        unique_id: pylontech_power
        value_template: "{{ value_json.summary.power }}"
        unit_of_measurement: "W"
        device_class: power
        state_class: measurement
      - name: "Pylontech State"
        unique_id: pylontech_state
        value_template: "{{ value_json.summary.state }}"

Restart Home Assistant. The 6 sensors appear under Settings → Devices & Services → Entities, searchable by pylontech.

Don't mix Option 1 and Option 2 for the same sensor. You'll get duplicate entities. Pick one method and stick to it. (You can still combine: MQTT for the four push-based values, and a single REST sensor for state/current if you really want both.)

Node-RED

Use an http request node, method GET, URL http://<DEVICE-IP>/api.json, return a parsed JSON object. Then read msg.payload.summary.soc (or any other field) downstream. If MQTT is configured on the device, you can also subscribe directly to pylon-monitor/state with an MQTT-in node — no polling needed.

Jeedom

Install the JSON plugin, point an equipment to http://<DEVICE-IP>/api.json, then map JSON paths to commands (e.g. summary>soc, summary>voltage, summary>state).