Getting Started

Virtual Smart Home (VSH)

Do stuff in Node-RED with Amazon Alexa โ€“ no custom hardware, no separate accounts, no hassle.

Virtual Smart Home (VSH) is a powerful Node-RED node that lets you create virtual smart home devices directly on your flow canvas. These devices integrate natively with Amazon Alexa using the Virtual Smart Home skill, allowing you to control and automate your home like never before.

Examples

โœจ Why Choose VSH?

  • ๐Ÿงฑ Drag & Drop Simplicity
    Add new virtual devices in Node-RED and they instantly appear in Alexa โ€” no discovery phrase needed.
  • โŒ No Extra Accounts
    Just link your Amazon account. No extra sign-ups, no cloud dashboards to manage.
  • ๐Ÿ”„ Live Sync with Alexa
    Rename or change device types, and Alexa reflects the changes in real time.
  • ๐Ÿ” Secure by Design
    Communicates via individually provisioned certificates using a secure cloud connection.
  • ๐Ÿ” Two-Way Sync
    Push updates from Node-RED to Alexa โ€” perfect for keeping things in sync when local changes happen.
  • ๐Ÿงน Automatic Cleanup
    Remove devices from Node-RED and they're automatically removed from Alexa, too. Orphaned devices? Clean them up easily in the editor.

๐Ÿš€ Supported Device Types

VSH supports a growing range of Alexa-compatible devices:

  • Blinds
  • Color Changing Light Bulb
  • Contact Sensor
  • Dimmable Light Bulb
  • Dimmer Switch
  • Doorbell Event Source
  • Entertainment Device
  • Fan
  • Garage Door Opener (en-US only)
  • Lock
  • Motion Sensor
  • Plug
  • Scene
  • Switch
  • Temperature Sensor
  • Thermostat (Single- and Dual-Setpoint)

โš™๏ธ How It Works

VSH connects Alexa voice commands to your smart home flows in Node-RED.

For example, when you say:

"Alexa, dim the kitchen light to 50 percent"

The node emits a msg object like this:

{
  "topic": "home/kitchen/lights",
  "metadata": { "foo": "bar" },
  "payload": {
    "brightness": 50,
    "powerState": "ON",
    "source": "alexa",
    "directive": "SetBrightness",
    "name": "kitchen light",
    "type": "DIMMABLE_LIGHT_BULB"
  }
}

You can use this msg to control physical devices โ€” for example, via MQTT or Home Assistant.

And it works both ways: Send a msg into the node to update Alexa with local state changes. If passthrough is enabled, Alexa gets updated and an outbound message is sent too (payload.source = "device").

๐Ÿง  Ideal For

  • Home automation enthusiasts who want voice control without cloud lock-in
  • Developers building custom smart home flows
  • Anyone who uses Node-RED and Alexa together

๐Ÿ“ฆ Get Started

Install from the Node-RED palette or via npm:

npm install node-red-contrib-virtual-smart-home

Then enable the Virtual Smart Home Alexa Skill and link your account.

๐ŸŒ Availability

The Virtual Smart Home Alexa skill is available in the following regions:

๐Ÿš€ Setup Instructions

Get up and running with Virtual Smart Home in just a few minutes.

๐Ÿ”Š Step 1: Enable the Alexa Skill

  1. Open the Alexa app on your phone or go to the Alexa Skill Store.
  2. Search for the "Virtual Smart Home" skill.
  3. Tap Enable and complete the account linking using your Amazon credentials.

๐Ÿงฑ Step 2: Set Up in Node-RED

  1. Install the VSH Node
    Add VSH to your Node-RED environment, either from the Node-RED palette or via npm:
    npm install node-red-contrib-virtual-smart-home
  2. Add a Virtual Device
    - Drag a virtual device node onto your flow.
    - Connect it to a debug node to inspect the output.
  3. Configure the Device
    - Double-click the virtual device node.
    - Enter a name (this will be the Alexa device name).
    - Choose a device type (e.g., dimmable light, switch, thermostat, etc.).
  4. Link Your Amazon Account
    - Click the pen icon next to the Connection field.
    - This step is required once per Amazon account.
    - Use the same Amazon account you used to enable the skill.
  5. Deploy Your Flow
    - Click Deploy in Node-RED.
    - Alexa will automatically discover your new virtual device.
    - If Alexa app notifications are enabled, you'll even get a push notification.
  6. Try It Out!
    Say something like:
    "Alexa, turn on kitchen light"
    - Check the output in the debug node to see what Alexa sent.
    - Use the output to control your real devices, trigger flows, or send MQTT messages.
  7. Removing Devices
    - Simply delete the virtual device node from your flow.
    - After redeploying, the corresponding Alexa device will be removed automatically.

Docs

Detailed docs are shipped as part of the Node-RED package and available through the 'help' panel.

Examples

Example flows that illustrate the payload structure and voice invocation phrases can be imported from the Node-RED import menu (Import > Examples > node-red-contrib-virtual-smart-home). They can also be found in the examples folder.