Exploring Weather-dependent Routines with SONOFF: Any Alternative Apps or Devices?

Hello SONOFF community,

I’ve been diving into the world of home automation with my SONOFF devices and I’m intrigued by the idea of setting up weather-dependent routines. I’m curious to know if anyone has managed to achieve this, either using the SONOFF ecosystem or by integrating other apps or devices.

If it’s possible to attain this goal through alternative means, I’d love to hear about your experiences. Perhaps there are third-party apps or additional devices that can help me incorporate weather conditions into my automation routines. For instance, I’m open to suggestions on whether platforms like IFTTT or Home Assistant could play a role in making this happen.

Your insights would be immensely valuable. Whether you’ve achieved weather-based triggers using SONOFF alone or with the help of external tools, please do share your wisdom. I’m excited to explore new avenues for making my home smarter and more responsive to changing weather conditions.

Thanks a bunch in advance for your guidance and knowledge sharing! :house_with_garden::sun_behind_rain_cloud:

In any scene you can do sunrise, sunset. With moisture, temp and humidity sensors on the TH switches etc, with allow you to set triggers based on wet, dry, hot, cold etc…

What more you need :crazy_face:

1 Like

:slight_smile: Thank you for making me laugh @Alex6 - sometimes we make our lives very complicated - I do it to myself as well…

@rennebueno - I have not tried to do it with the weather, but I did do something which might give you an idea. I have solar power system (PV panels, batteries, inverter) which is connected to the grid as well - a so-called hybrid system. I wanted to control certain devices depending on the state of the PV panel power output, state of the batteries, if the grid is on, and some other parameters. My inverter writes all this information to the supplier cloud every 5 minutes.
So, I asked a friend to develop an app on a Raspberry PI for me, which uses an API from my solar system supplier to get the data from the cloud every 5 minutes. It has a local browser interface so I can manage and fine tune the parameters. The app on the Raspberry PI triggers a relay, which gives me a dry contact signal to a MINI R2. I used this as the trigger for scenes to control some equipment so that I do not drain my batteries. I attach a picture.

This is a little extreme, and I kind of did it as a challenge :slight_smile: But perhaps, if you can find weather information that you can reach via API, you could follow this approach.


The free version of IFTTT is quite restrictive in how many automations you can set up. “Olisto” is a Dutch company who do similar and aren’t restricted, but every few weeks something disconnects. Home assistant is the most reliable but also the most hassle. Sonoff sell a device called the iHost which can run scenes locally. It is quite like an easy home assistant but not as flexible.

Drop me a WhatsApp please. 0813908907. Would like to pick your brain if possible.


I’ve set up a device to turn on and off based on weather conditions. When it’s raining, the weather sonoff turns on, and the pump sonofff’s are not to activate. You can manually set the rainy condition or use IFTTT applets for that.

I use a Sonoff SV to control my Rainbird 13-station irrigation controller, which is an older model and cannot be upgraded to be WiFi capable. I set the SV up as a dry switch (no power) directly on the irrigation controller’s external rain sensor contacts. Closing the circuit tells the Rainbird that it is raining and it must not start the irrigation cycle.

The SV comes with instructions to separate the WiFi and logic circuit from the switched circuit for this purpose (by snapping off two small resistors on the PC board). This works fine to remotely control the irrigation, but I like your idea to automate it using IFTTT applets. Please share if you got it to work, and which applet you used? :slight_smile:

Take a look

1 Like

Ive the same needs. Of course I dont mean the “basic” weather conditions (i.e. temperature, Humidity etc) but, for instance, the necessity to close the roof window if the wind arise above x mph or similar. Ive tried via IFTTT (pro+) but it doesnt work properly (rarely to be honest). IFTTT is based on Weather Underground but the routine, as said, is a real flop.
I hope Sonoff will give soonest the possibility to increase the scenario’s exceeding the “basic” weather conditions

I have an Ecowitt weather station at home - and there seems to be a way to get the data into Home Assistant via MQTT

Hi. Perfect for me!!!
Could you make me in contact to your friend in order to understand if can be done the same with my Huawey fusion solar? I want to start some scene automatically based of some state of the PV sistem.

I’ll pay for it.

Hi Marco
I had a quick look and it seems that your system indeed has a realtime (5 min intervals) data query capability. So, you would be able to do something similar. Look at this link and read the posts further down in the thread - there are some links there. You could even try it out by doing an API call directly from your browser. It will return the data to your browser session where you launched the API:
FusionSolar API Realtime Consumption Data (huawei.com)

I also found API documentation here: FusionSolar API Realtime Consumption Data (huawei.com)