Now we create a virtual switch in Domoticz, we use this switch later for our Sonoff and Homebridge accessory.

Open Domoticz in our case and click Hardware.

 Add Hardware Domoticz

Now we create a Dummy

Name: Virtual switch
Type: Dummy

And click Add.

Create Dummy switch Domoticz

Now click create virtual sensors.

Create virtual sensors

Name: Virtual Switch
Sensor type: Switch

Hit OK.

Now click Switches on the top of the page.

Create virtual sensors Domoticz

Our Virtual switch is created.

Switchscreen Domoicz