Shelly Script Examples
This project contains example Shelly Script solutions.
Initial support for Shelly Script comes with firmware version 0.9, September
2021 for Gen2 Shellies based on ESP32.
Who is this for?
This repository is designed for:
- Home automation enthusiasts - Looking to extend Shelly device capabilities beyond the default features
- Smart home integrators - Building custom solutions with Shelly devices for clients
- Developers - Learning Shelly scripting through practical, working examples
- IoT hobbyists - Experimenting with BLE sensors, MQTT, LoRa, and other protocols
- Energy-conscious users - Implementing load shedding, power monitoring, and efficiency solutions
Prerequisites:
- Basic understanding of JavaScript
- Shelly Gen2 or Gen3 device with firmware 0.9+
- Access to the Shelly web interface or app for script deployment
Documentation
- Script Index - Full list of all example scripts with descriptions
- Changelog - See what's new
- Contributing - How to contribute to this project
- Tools - Helper utilities for uploading scripts and validation
- License - Apache License 2.0
- Shelly Script Documentation - Official Shelly scripting docs
Collections
- The Pill - UART peripherals and hardware integrations
- BLU Assistant - BLE device provisioning, configuration, and management scripts
- Cury - Expressive light patterns and visual feedback for Shelly Cury devices
Repository Layout
- ble/ - BLE/BLU sensors, buttons, and gateways
- howto/ - Minimal examples and tutorials
- http-integrations/ - HTTP endpoints, notifications, and external services
- lora/ - LoRa send/receive and device control examples
- mqtt/ - MQTT and Home Assistant integrations
- networking/ - Provisioning and watchdog scripts
- power-energy/ - Load management, power thresholds, and monitoring
- scheduling/ - Scheduling, scenes, and orchestration
- switch-input/ - Input handling, switch behavior, and cover control
- weather-env/ - Weather and environmental sensor integrations