Skip to main content

Library for Shelly smart home devices

Project description

founder-wip buy me a coffee

stability-wip PyPI


Library for Shelly smart home devices. Using CoAP for auto discovery and status updates.

This library was created for Shelly Plugins for Home Assistant and Telldus Tellstick Net/zNet v2.


  • Discover devices
  • Monitor status
  • Monitor switch status
  • Control (turn on/off etc)
  • MQTT Server
  • MQTT Client
  • Websocket
  • Run only locally
  • Support user name and password
  • Coexist with Shelly Cloud and Shelly app
  • Support static and dynamic ip address
  • mDns and MQTT discovery
  • Cloud support (Get names of devices etc)

Devices supported

  • Shelly 1
  • Shelly 1 PM (bug in firmware)
  • Shelly 1L
  • Shelly Addon for 1/1PM, temp and humidity
  • Shelly 2 (relay or roller mode)
  • Shelly 4 Pro
  • Shelly Plug
  • Shelly Plug S
  • Shelly Plus 1
  • Shelly Plus 1PM
  • Shelly Pro 4PM
  • Shelly BULB
  • Shelly RGBWW
  • Shelly RGBW2
  • Shelly H&T
  • Shelly EM
  • Shelly 2.5 (relay or roller mode)
  • Shelly 2LED
  • Shelly Flood
  • Shelly Door/Window
  • Shelly Door/Window 2
  • Shelly Dimmer
  • Shelly Dimmer 2
  • Shelly EM
  • Shelly 3EM
  • Shelly DUO
  • Shelly Vintage
  • Shelly i3
  • Shelly Button 1
  • Shelly Gas
  • Shelly Air (not tested)


from pyShelly import pyShelly

def device_added(dev,code):
  print (dev," ",code)

shelly = pyShelly()


while True:


Please give us feedback on or Facebook groups: Shelly grupp (Swedish) or Shelly support group (English)


This plugin is created by the, the Swedish distributor of Shelly. In Sweden you can buy Shellies from or any of the retailers like NetOnNet, Kjell&Company etc.

buy me a coffee

Project details

Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pyShelly, version 0.3.5
Filename, size File type Python version Upload date Hashes
Filename, size pyShelly-0.3.5.tar.gz (34.7 kB) File type Source Python version None Upload date Hashes View
Filename, size pyShelly-0.3.5-py3-none-any.whl (42.4 kB) File type Wheel Python version py3 Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page