Tp-link kp400

TP-LINK KP400 does not work in 96.5. problem is it’s a two outlets and HA only report one that turns both on. but a moment later it returns to indicating off when the outlets are on. It would be nice to be able touse this with HA. Any Takers out there.

Tom B.

Hoping someone can take this one before Christmas time! :slight_smile: may be willing to add this…

Commenting to keep this relevant, because I just bought one and it is disappointing I cant use it with Home Assistant. I am so ingrained in HA that anything that doesn’t work in it is practically useless because I refuse to use another app

Just made a PR on code that works for me inside a custom component:

That is fantastic news, thanks @gjbadros !!! I can’t wait to see your PR added to Home Assistant! I took a look at your code and am really curious as to if it will also work on the TP-Link HS300 power strip. I don’t see why that wouldn’t work, also. Basically this could add support for all multiple/child objects on the TPLink style power strips.

Does anyone have a HS300 they could try to validate? I have been holding off buying the multiple outlet TPlink switches, but it looks like I’ll be getting some of these shortly!!! Both the KP400 and HS300.

Yea I tried to make it work more generally… I wasn’t aware the smartstrips even existed until I read the pyHS100 code. I just ordered one and it should arrive tonight so I can test it.

Just noticed the HS300 also has energy monitoring as an added bonus. I know that at least one of the existing TP-Link switches has this and is supported in HA.

I noticed the same thing when reading the pyHS100 code. Hoping your tests go well and we can get this all added into the release HA well before Christmas time. :slight_smile: That will really help since I need a good outdoor switch solution for the lights.

TP-Link also has hard-wired indoor outlets (KP-200). I’m wondering if your code will support all the other multiple switch devices, like that one too!

I just tested the smart strip and it looks like the emetering code from pyHS100 needs updating for the smart strip emetering support. I can make the HS300 strip almost work if I catch some keyerrors, but I strongly suspect the right fix is a change to pyHS100 (or a bump to the latest version of pyHS100). Possibly one of the hass reviewers will have experience with the pyHS100 code base and an ability to do a new release there for hass to state as a new dependency.

Regardless, I’m confident in my patch for the outdoor switches and I’m hopeful it’ll get merged soon, long before Christmas. I’m pretty interested in the smart strips, too (though I also really like wattbox ethernet-based IP-controllable outlets which I built support for in hass but not in the general release yet).

Was checking tplink related pull requests today and noticed @mattkasa created one for HS300 and HS107 support! Between his pull request and yours, fans of tplink devices and HA will be VERY happy! You can see his request here:

Looks like I’m going to be ordering a KP400 and maybe an HS300 soon! :slight_smile:

1 Like

Oh cool, thanks for the pointer… I’ll comment on that one since there is a lot of commonality – in particular my PR avoids a breaking change, but theirs uses a plugs member of the SmartStrip that, if it works for all of the devices, will be simpler than my extension of SmartPlug.

So it appears that as of 0.101 the kp400 has been added to Home assistant (, but I cannot get it to work… Every time I add a “strip” entity to my configuration for tplink it breaks the integration. Anyone have any luck getting it running?

Running 0.103 over here now and have a KP400 for my outside Christmas Lights. Working perfectly with Home Assistant. Here is all the tplink configuration from my setup:

  discovery: false
# Marks Office Light
    - host:
# Marks Office Salt Lamp Switch
    - host:
# Marks Office M Light Switch
    - host:
# Outdoor Lamp Post
    - host:
# Outdoor Front Lights
    - host:
# Alexs Room Light
    - host:
# Alex Humidifier
    - host:
# Mark Humidifier
    - host:
# Christmas Tree
    - host:
# Christmas Train
    - host:
# Living Room Lamp
    - host:
# Christmas 1st Floor Bedroom
    - host:
# Christmas Alex Room
    - host:
# Christmas Foyer
    - host:
# Christmas Foyer 2
    - host:
# Christmas Living Room
    - host:
# Outdoor Lights Plug 1&2
    - host:

Yeah, I think one of the minor updates after .101 fixed it. I got it running a couple of weeks or so after posting. Thanks for checking though! I should have updated when I got it running