Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time


HomeKit support for the Nissan Leaf using hc and my Carwings Go library.

When running, this service publishes a single HomeKit accessory exposing three services:

  1. A battery service indicating the current charge of your Leaf and its charging status.
  2. A switch service indicating whether the Leaf is currently charging. If the Leaf is plugged in but not charging, you can flip this switch on to begin charging the vehicle.
  3. A fan (v2) service for the Leaf's climate control. Flipping this switch toggles the vehicle's climate control system.

After the vehicle is paired with your iOS Home app, you can control it with any service that integrates with HomeKit, including Siri ("How much battery does the Leaf have?") and Apple Watch. If you have a home hub like an Apple TV or iPad, you can control the Leaf remotely.


The tool can be installed with:

go get -u

You will need to create a config.json file with your Carwings username and password, like so:

    "username": "",
    "password": "carwingsPassw0rd"

Then you can run the service:

carwings-homekit -config config.json

The service will make an initial call to the Carwings service to get updated and current battery and climate control information, and then expose the service.

To pair, open up your Home iOS app, click the + icon, choose "Add Accessory" and then tap "Don't have a Code or Can't Scan?" You should see the Leaf under "Nearby Accessories." Tap that and enter the PIN 00102003 (or whatever you chose in config.json). You should see two entries appear in your list, one for the charging switch and one for the climate control fan.


Issues and pull requests are welcome. When filing a PR, please make sure the code has been run through gofmt.


Copyright 2017 Joe Shaw

carwings-homekit is licensed under the MIT License. See the LICENSE file for details.


No releases published


No packages published