Connecting Home Assistant to Staykey
Staykey integrates with Home Assistant to provide fast, reliable control of your smart devices. This guide walks you through connecting your hub.
Requirements
Before connecting, you'll need:
- Home Assistant installed and running (Home Assistant Green recommended)
- A publicly accessible Home Assistant URL — Staykey connects to your hub over the internet, so local-only URLs like
http://homeassistant.local:8123 won't work
- A Staykey account with at least one property added
Making Home Assistant publicly accessible
Staykey needs to reach your Home Assistant instance from the cloud. Choose one of these methods to expose your hub securely:
Nabu Casa (Home Assistant Cloud)
- Easiest setup (~5 minutes)
- $6.50/month subscription
- Supports Home Assistant development
Tailscale Funnel
- Free option
- Good for technical users
- Takes ~15 minutes to set up
Once your Home Assistant has a public URL, continue with the steps below.
Step-by-step connection
- Open Integrations: In Staykey, go to Properties → Manage → Manage Property → Integrations for the property you're connecting.
- Add Home Assistant: Click Add Integration and choose Home Assistant.
- Enter your public URL: Use your Nabu Casa URL (e.g.,
https://xxxxxxxxxx.ui.nabu.casa) or Tailscale Funnel URL (e.g., https://your-hostname.tail-scale.ts.net).
- Create a Long-Lived Access Token: In Home Assistant, go to Profile → Security → Long-Lived Access Tokens and generate a new token.
- Save the token securely: Copy it to a password manager immediately—Home Assistant won't show it again.
- Connect: Paste the token into Staykey and click Connect.
- Select devices: Click Edit under Devices and choose which locks, thermostats, switches, or other devices Staykey should manage.
Optional: Install the Staykey plugin
For enhanced lock activity tracking (like seeing which code was used to unlock), install the Staykey Home Assistant plugin. This forwards keypad events from your Z-Wave locks to Staykey.
Token security
Long-Lived Access Tokens are sensitive. Treat them like passwords:
- Store tokens in a password manager
- Rotate tokens if they're ever exposed
- Remove unused tokens from your Home Assistant profile
- Use a dedicated token for Staykey (don't share tokens across services)
Verify your connection
After connecting, you should see your Home Assistant devices listed in Staykey. If devices don't appear:
- Verify your Home Assistant URL is publicly accessible (try opening it in a browser from your phone with WiFi off)
- Check that the access token hasn't expired or been deleted
- Ensure the devices are available in Home Assistant itself
Troubleshooting
- "Cannot connect" error: Double-check your public URL is correct and accessible from outside your network
- Devices not appearing: Refresh the integration in Staykey and re-run device discovery
- Token errors: Generate a new Long-Lived Access Token and update it in Staykey
Need more help? Check our device connection troubleshooting guide.
Still have questions? We're here to help.