Need help with home-automation?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

3.4K Stars 267 Forks MIT License 48 Commits 11 Opened issues


Raspberry Pi 3 based home automation with NodeJS and React Native.

Services available


Need anything else?

Contributors list

# 16,773
React N...
47 commits

Home Automation with RPi and Javascript

Updated article:


Link to video

Alt text


Since a kid I've been passionate about electronic and different kind of mechanisms. Previously I've done different small projects with arduino, like handbrake for my gaming steering wheel, custom LED tachometer for my car (see my github repo), voice controlled LEDs and so on. Recently I bought Raspberry PI 3 and around all the IoT hype, I decided to start automating my home.

The Technology Stack

Since I'm pretty familiar with javascript and its ecosystem I decided to create my own phone app via

react native
and connect it via
backend. I'm using ImmutableJS's Records for consistency of the data structure and the performance of the app. The data is sent between the client and the server via JSON strings, which are converted to back to Immutable records, when received on both sides. I've separated the shared modules(between client and server) to a separate local npm packages - home-records and home-config. For GPIO controlling (pins of the raspberry) I've used
library, together with
. Since I couldn't find codes for my AC, I've recorded them by myself and added them to
config file.
cron is used as dynamic dns, because my IP address changes periodically and I won't have to recompile the whole app or change config each time. The server broadcasts the changes to all connected users realtime. The phone app is located in /phone-app folder, the server is located in /server. Why don't you take a look?

The Hardware

Raspberry Pi 3
is the controlling unit. High-power devices, such as LED strips, are powered via external
12V 5A power supply
(shared ground with the PI). The AC is controlled via 950nm infrared LED. The heating system is wired via relay (on and off) and servo for the thermostat as I was avoid disassembling. Both white LED strip and the RGB strip are connected via
logical transistors to the PI. There is also IR receiver, just in case I want to record anything else. Temperature is measured via DS18B20 temperature sensor.

The wiring looks like:


New Ideas

I'm open for all kind of ideas about different modules. If you have some ideas in mind, I'll be thankful if you add it in the issue tracker and label it as


Software dependencies

  • Node & Npm
  • Pi-Blaster
  • WiringPi
  • Lirc

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.