Govee Integration for Govee Light, Switches, Plug, and now Appliances

The problem is they are trying to do to much and it has gotten cluttered becasue of it. They really need to streamline the app and only include info that is useful.

I have looked at the curtain light scenes and there is no doubt there is some kind of issue occurring. It isn't related to the size of the command data though as some commands that work are very long as well. I will need to take another pass at the how the scenes look in the preload section vs how they look when extracted. It is possible I screwed something up when doing the reformat for to put in the preload section of the code that broke something.



I believe i see what broke it. I am not sure yet what i need to do to fix it though.

@williamsca68 after further testing what i saw isn't actually a valid problem. I don't know why it isn't working actually. The problem is there isn't any error really. The problem is the command is sent to the Govee Curtain's controller and it isn't acting on it. Generally that has occured when the command is invalid in the past. So for my only thought is that for some reason their controller isn't responding to the commands as it should.

I will see about reaching out to Govee Support and try to get help, but this may be a grey area for me to get it.

I have left them feedback and not much changes. To me, the forums are the biggest part of the issue, but there are many problems with that app.

I am an old fuddy-duddy I guess, but I hate reading things like that on a phone, especially if you are trying to follow along on something like a tutorial while you are also simultaneously trying to use the same exact app to do the actions.

Thank goodness I can do many of the common and simple things on Hubitat due to this integration. I have a couple "wish list" items for this Hubitat integration, but overall it sure saves a lot of time and effort.


Whats on your wish iist?

Just released 1.0.48

Thank you to @Eric.C.Miller who extracted new scenes for Outdoor String Light Devices. They have been added.

Improvements to the button/commands setNextEffect and setPreviousEffect have been made to provide a good flow between early Wiz Scenes and Govee Preloaded scenes and manage cycling through them all of them.

Because of a new value to provide awareness of how many scenes are available on a given device you may want to go to the Scene Management menu and click on the button "Reload Preloaded Scene Data" and then"Refresh device scene awareness". This will prompt every device to run through the process to obtain this value.

I am still waiting on information from Govee about the scene issue with the curtain lights.

1 Like

Hello @mavrrick58,

I feel like I should be able to figure this out, but I’m stumped.

I’m receiving an error when I attempt to add DIY scenes. In the app it’s “Cannot invoke method get() on null object”.

In the logs I see:
app:3602023-11-12 09:17:36.774 PMerrorjava.lang.NullPointerException: Cannot invoke method get() on null object on line 388 (method sceneExtract)

app:3602023-11-12 09:17:36.717 PMdebugsceneExtract(): found Default group moving forward

app:3602023-11-12 09:17:35.750 PMdebugsceneExtract(): Calling HTTP server

app:3602023-11-12 09:17:35.749 PMdebugsceneExtract() DEVICE INFORMATION

I’ve setup the LAN Enabled device, model H61721D1. I’ve tried uninstalling/reinstalling and also using a new API key.

I must be missing something. Thanks for your help.


Try going into the scene management menu and clicking the button to "Clear DIY Scenes"

No luck.

From the light child object:
dev:12172023-11-12 09:17:05.237 PMerrorjava.lang.NullPointerException: Cannot invoke method get() on null object on line 557 (method activateDIY)

dev:12172023-11-12 09:09:18.847 PMerrorjava.lang.NullPointerException: Cannot invoke method containsKey() on null object on line 573 (method initialize)

From the App logs:
app:3602023-11-13 12:05:57.344 AMerrorjava.lang.NullPointerException: Cannot invoke method get() on null object on line 388 (method sceneExtract)

app:3602023-11-13 12:05:57.297 AMdebugsceneExtract(): found Default group moving forward

app:3602023-11-13 12:05:56.934 AMdebugsceneExtract(): Calling HTTP server

app:3602023-11-13 12:05:56.933 AMdebugsceneExtract() DEVICE INFORMATION

OK so there are a few things that don't add up here..

This error is basically complaining that the data included in response from govee isn't valid. It isn't able to parse what was returned. This would likely be caused by a Tap-Run that doesn't include an actual scene on a device, but instead includes something like a dreamview or somthing that doesn't include device specific info. I think the problem here is bad positioning for of that line of code for logging what device was found. I have fixed that and if you do a repair in HPM on the Govee Integration that error should go away with a new message saying that a device was not found and the extract was ignored. Make sure your "Tap-To-Run" is for a device or snapshot of a device and not something like music, dreamview, or device group.

These errors on the devices don't make any sense at all. Those lines of code don't are not related to what to this process at all. To help me understand what is happening here can you check a few things

  1. Do a repair through HPM and make sure you are running the latest version of code.
  2. What devType Value showing the the data section of the device info. It should be RGBIC_Strip
  3. What driver is the device using.

Amazing work so far, curious as I do not see it covered here I am trying to automate the following with my Govee outdoor lights:

  • Turn on Music Dreamview
  • Change Carnival Presets (Fluctuate, Pulsate, Shimmer...etc)

I have found no way to do this through Govee App, HA, Alexa or Google. You can control other things but not specifically Music Dreamview. Long story short I have outdoor lights setup through the music dream view group and I want to play music and change the music dreamview presets between each song.

Is there anyway to do this with Hubitat?

Below are my Govee outdoor models, I have my API key as well:
H1167 - Outdoor Music Sync Box
H70C1 - Christmas String Lights
H61A8 - Outdoor Rope Light
H705A - Outdoor Permanent Lights
H70B1 - Curtain Lights
H7065 - Outdoor Spot Lights

Not for sure if all of the models matter or if we can just turn on Music Dreamview? I know if I have the Govee lights on music dream view and turn them off and then turn them back on they remember the preset they were on, but I need to be able to change the Music dream view presets that is a must!

Any help would be greatly appreciated, I would even pay for help setting this up!

@rich8 and @williamsca68

Unfortunately anything to do with Music Dreamview or any Dreamview/grouping function is not going to be possible from what I can tell. Those functions don't specify anything specific in the space were the device extract is pulled. They also depend on the Govee Cloud to functions instead of being able to be done locally.

You may be able to setup a snapshot on each device that puts each device in Music Mode and then use individual tap-To-Runs to extract it. Then once they are all extracted have a rule in HE call each device and set the extracted DIY for that music mode on each device. The question would be if each device even has a standard Music mode effect that will work with what you are trying to do.

@rich8 and @williamsca68
With the above said though I just heard back from Govee reguarding the issue with the scenes involving the Curtain Lights. Two things came out of their response.

  1. They don't appear to recommend or be aware of how the scene data is being communicated over LAN API. They asked me to provide details as to how it is working.
  2. They also stated
    "in the future, it will provide an openAPI to control scenes/DIY, Music Mode, ect."

This is a interesting turn of events as this could dramatically make this easier to deal with. The question is just when. This may also apply to Dreamview stuff, but we won't know until we can see it in action. We will just have to wait and see where that goes.

1 Like

I have been trying to find a way to get my scenes going for both my non-LAN bulbs and my strip lights. Strip lights were easy since you can do the scenes via this integration but it took me until today to realize that the Govee Tap-to-Run scenes are exposed to both Google and Alexa when you link your accounts. At least with Google I didn't even have to add any of the Govee devices (didn't want them duplicated since already shared from Hubitat) to make the scenes available.

I created a virtual switch in Hubitat called "christmas govee" and exposed that via the built in Google integration with Hubitat (auto-off after 10 sec). Then set up a household routine in Google Home to trigger on that switch turning on, and added the action of turning on my Christmas scene. You can set DIY options for the bulbs and strips, which include scenes.

So, it was a minor workaround to get it working, but the handful of times that I have tested it, it has been pretty instantaneous from the time I push the virtual button to all of my lights turning on and getting set with the scene. Definitely will remove the Google man-in-the-middle if they open up the API in the future, but for now hopefully this helps someone.

1 Like

Awesome work on the HE Govee app. I just added the HE app and am working on getting this set up. I do have a question regarding the predefined scenes.

I have the Permanent Outdoor lights that use the 705A controller. In the Govee android app there are about 90 scenes that are selectable. After setting up the HE app, I only see about 53 scenes available to my devices. I read your "Extract Govee Scene" document and wondered if I needed to do this to extract the additional scenes. Not that I need all of these scenes but was curious if that was the proper way to add them.

It seems it isn't uncommon for Govee to add preloaded scenes at times they update firmware. They probably added scenes after the intial pull was done by a wonderful community member here since I don't have them.

To answer your specific question I don't remember if that document was updated with the latest procedure. Initially doing the extraction was a bit harder then it is now. The process is as follows.

  1. Go into the Govee Integration app and go to the Scene management menu.
  2. Then click on the option to setup your "Govee Home Creds".
  3. Put in your user id and password for the Govee home app and click on the button to "Click her to attempt login. If successful you will see a line right below the button saying "Token is valid". Click on the Next button.
  4. Just to ensure we don't have a issue click on the button to "Clear/Intialize DIY Scene information"
  5. In the Govee Home app setup your "Tap-To-Run" and take note of the group it is part of.
  6. Back in the Govee Integration app you should now be ready to perform the extraction. Just click on option to "Extract Scene"

If all works well you should get a display that shows the device name, scene name, the command and the model. then it is just a matter of updating the tap to run for each scene you want to extract and then click on the button to do the extraction.

Once all of them are extracted you need to get them to me. Click on the gear in the upper right corner of the app to see all of the app setup details. scroll down a little bit and you should see a "diyEffects" object under the application state section. Copy and paste the entire value from that field into a DM and send it to me. I will get it formatted and update the current list of scenes in the main app so everyone can use it.

Once I update the app you should probably do the "Clear/Intialize DIY Scene information" again to remove the extracted data since it shouldn't be needed.

1 Like

I will work on updating that list and then send it to you. I was able to add a "snapshot" so I believe what you posted above was the process I used for that as well. I will clear the diy first so I don't send you my "snapshot" string.

1 Like

I'm wondering if anyone has found a decent tutorial for making your own effects (DIY) for Govee strip lights? I've got an H6173 and an H6172 on my deck rails/stairs and they look great. But, I'd like to make my own DIY schemes/themes. I find the iPhone app to be ridiculously complex. There's also references to uploading your DIY lighting effects, which would seem to hint that you could download someone else's DIY effects. But, I can't find that either. I know I'm whining, but their app is a UX disaster, but their products seem really solid...

Any pointers would be much appreciated!


I installed via HPM, but the app does not show in my list of Hubitat apps. Anyone know why this might occur?

I can see the code and all the drivers in the dev tool areas, and it shows as installed in HPM. (I tried repairing and uninstalling and reinstalling, but it still won't show. I'm sure it is user error on my part..

I will test, but the only thing i can think of is if you click on the button to "Add Built-in app" instead of the button to click on "Add User App"

1 Like

I was right, user error.. Thanks! I did not realize I had to add it from there after adding it via the HPM. Thanks so much for the fast reply to my clear user error! :sweat_smile:

1 Like