How Do I Resolve S2 Security Key Mismatches After Migrating Z‑Wave Devices to a Matter Bridge?

You finally decided to future-proof your smart home. You grabbed a Matter bridge, started migrating your Z-Wave devices, and then — everything stopped working. Your door lock won’t respond. Your thermostat shows “unavailable.” Your hub keeps throwing cryptic security errors.

Sound familiar?

I’ve been there. Last spring, I migrated 23 Z-Wave devices from a SmartThings v3 hub to a new Matter-compatible bridge. Within an hour, half my devices were offline, and the logs were flooded with one recurring message: S2 security key mismatch.

It took me three full evenings to figure out what went wrong and how to fix it properly — without losing my device configurations, automations, or sanity. This guide is everything I wish someone had told me before I started.

Whether you’re dealing with a single stubborn lock or a house full of unresponsive sensors, I’ll walk you through exactly what’s happening, why it happens, and how to resolve it safely — step by step.

What Is S2 Security in Z-Wave and Why Does It Matter?

Before jumping into fixes, let’s understand what we’re actually dealing with.

The Basics of S2 Security Framework

Z-Wave S2 (Security 2) is the encryption protocol introduced in 2017 that replaced the older S0 framework. It uses Elliptic Curve Diffie-Hellman (ECDH) key exchange to create a secure communication channel between your Z-Wave controller and each device.

Think of it like this: when you first pair a Z-Wave device, both the controller and the device agree on a “secret handshake.” That handshake is the S2 security key. Every command sent between them — lock the door, turn off the light, read the temperature — is encrypted using that key.

S2 Security Classes Explained

S2 isn’t one-size-fits-all. There are three distinct security classes:

  • S2 Unauthenticated: Basic encryption, no physical verification required
  • S2 Authenticated: Requires a DSK (Device Specific Key) — usually a 5-digit PIN printed on the device
  • S2 Access Control: Highest level, mandatory for door locks and security devices

Each device stores its assigned security class and the corresponding key. When you migrate to a Matter bridge, these keys don’t automatically transfer. That’s where the mismatch begins.

[📷 Image Placeholder: Diagram showing the three S2 security classes and which device types use each level]


Why S2 Key Mismatches Happen During Matter Bridge Migration

Understanding the root cause saves you hours of trial and error. Here’s what’s actually going on behind the scenes.

The Core Problem: Keys Are Controller-Specific

Every Z-Wave controller generates its own unique set of S2 network keys. When your Z-Wave device was originally paired, it received and stored keys from your original controller.

When you introduce a Matter bridge — whether it’s an Aeotec Z-Wave to Matter bridge, a Zooz ZST39, or a Nabu Casa SkyConnect with Z-Wave firmware — that bridge has its own controller chip with its own set of keys.

The device is still holding the old keys. The new bridge is offering new keys. They don’t match. Communication fails.

Common Scenarios That Trigger the Mismatch

Based on my own experience and what I’ve gathered from community forums, these are the most common situations:

Scenario 1: Direct Migration Without Exclusion
You try to add devices to your new Matter bridge without first properly excluding them from the old controller. The device still holds the old S2 keys and refuses the new ones.

Scenario 2: Backup and Restore Gone Wrong
You backed up your Z-Wave network from the old controller and restored it on the new bridge. But the backup didn’t include the S2 keys (some backup tools strip them for security reasons), or the keys were corrupted during transfer.

Scenario 3: Mixed S0 and S2 Devices
Some of your older devices were using S0 security, while newer ones use S2. The Matter bridge tries to communicate using S2 with devices that were originally included with S0, causing a protocol-level mismatch.

Scenario 4: DSK Verification Skipped
During re-inclusion, the Matter bridge prompts for the device’s 5-digit DSK PIN, but you skip it or enter it incorrectly. The device gets included without proper S2 authentication, resulting in a downgraded or failed security negotiation.

[📷 Image Placeholder: Flowchart showing the four common scenarios that cause S2 key mismatches]


How to Identify an S2 Security Key Mismatch

Before you start fixing, you need to confirm that an S2 key mismatch is actually your problem — not a range issue, a firmware bug, or a dead device.

Signs You’re Dealing With a Key Mismatch

Here’s what to look for:

  • Device shows as “included” but won’t respond to commands
  • Status shows “unknown” or “unavailable” in your smart home dashboard
  • Secure commands fail, but basic NIF (Node Information Frame) queries succeed
  • Your Z-Wave logs show entries like:
    • S2 key exchange failed
    • Security handshake timeout
    • SECURITY_2_NONCE_GET failed
    • Cannot decrypt message from node XX

Checking Your Z-Wave Logs

If you’re using Home Assistant with Z-Wave JS, you can check logs directly:

  1. Go to Settings → Devices & Services → Z-Wave JS → Configure
  2. Click on the affected device
  3. Look at the Security Class field — if it says “None” for a device that should have S2, you’ve confirmed the mismatch
  4. Enable debug logging temporarily to see detailed security negotiation failures

For other platforms like Hubitat or SmartThings, check your hub’s engineering logs or Z-Wave details page for similar security class information.

[📷 Image Placeholder: Screenshot example of Z-Wave JS device page showing security class information and where to find it]


Step-by-Step: Resolving S2 Key Mismatches the Right Way

Now for the part you came here for. I’m going to walk you through the process I used to fix all 23 of my devices. It works. It’s safe. And it protects your device configurations as much as possible.

Step 1: Document Everything Before You Touch Anything

This step saved me twice. Before making any changes:

  • Screenshot every device’s current settings (parameters, associations, names)
  • Export your automation rules that reference these devices
  • Write down each device’s location, node ID, and security class
  • Photograph the DSK/PIN labels on your devices (usually on the back or inside the battery compartment)

I keep a simple spreadsheet:

Device NameLocationNode IDOld Security ClassDSK PINNotes
Front Door LockEntry12S2 Access Control34512Yale Assure 2
Motion SensorHallway15S2 Authenticated78234Zooz ZSE18
Dimmer SwitchLiving Room8S2 UnauthenticatedN/AInovelli Red

Step 2: Properly Exclude the Device From the Old Controller

This is the step most people skip — and it’s the single biggest cause of problems.

Why it matters: Z-Wave devices can only be securely paired to one controller at a time. If you don’t exclude first, the device still holds the old keys and will reject new pairing attempts, or pair insecurely.

How to do it:

  1. On your OLD controller/hub, initiate Z-Wave exclusion mode
  2. On the device itself, trigger the exclusion sequence (usually a specific button press pattern — check the device manual)
  3. Wait for confirmation that the device has been successfully excluded
  4. Verify the device no longer appears in your old controller’s device list

Important safety note: If your old controller is already dead or inaccessible, you can still exclude the device using your new Matter bridge. Most Z-Wave controllers can exclude devices that were included on a different network — this is by design in the Z-Wave specification.

Step 3: Factory Reset the Device (When Necessary)

If exclusion fails or your old controller isn’t available, a factory reset is your next option.

When to factory reset:

  • The old controller is damaged or unavailable
  • Exclusion was attempted but the device still holds old keys
  • The device is stuck in a half-included state

How to factory reset common device types:

  • Door Locks (Yale, Schlage): Usually involves removing the battery, pressing and holding a specific button, then reinserting the battery
  • Sensors (Aeotec, Zooz): Typically a button press sequence (e.g., press the action button 5 times rapidly)
  • Switches (Inovelli, GE/Jasco): Often involves pressing the up/down paddles in a specific pattern

⚠️ Warning: Factory resetting a lock will erase all user codes stored on the device. Make sure you have those codes backed up before proceeding.

[📷 Image Placeholder: Photo examples showing reset button locations on common Z-Wave devices — lock, sensor, and switch]

Step 4: Prepare Your Matter Bridge for Secure Inclusion

Before you start adding devices back, configure your Matter bridge for the highest security:

  1. Update your bridge firmware to the latest version — security negotiation bugs are common in early firmware releases
  2. Ensure your bridge supports S2 — some early Matter bridges only support S0 or no security for Z-Wave devices
  3. Have the device’s DSK ready — you’ll need the 5-digit PIN for S2 Authenticated and S2 Access Control inclusion
  4. Position the device close to the bridge during inclusion (within 3 feet / 1 meter) — S2 key exchange requires reliable communication

Step 5: Re-Include the Device With Proper S2 Security

This is the critical step. Take your time here.

  1. Put your Matter bridge into inclusion mode (the exact method depends on your platform)
  2. Trigger the inclusion sequence on the device (again, check the device manual)
  3. When prompted for the DSK PIN, enter it carefully — this is not optional for locks and security devices
  4. Select the appropriate S2 security class when prompted:
    • Choose S2 Access Control for door locks, garage controllers, and alarm systems
    • Choose S2 Authenticated for sensors, thermostats, and cameras
    • Choose S2 Unauthenticated only for devices that don’t support higher levels
  5. Wait for the full inclusion process to complete — don’t interrupt it, even if it takes 30-60 seconds
  6. Verify the security class in your bridge’s device details page

Step 6: Verify Secure Communication

After inclusion, test thoroughly:

  • Send a command to the device (lock/unlock, on/off, etc.) and confirm it responds
  • Check the security class assigned in your controller — it should match what you selected
  • Monitor logs for 5-10 minutes to ensure no security errors appear
  • Test from Matter-connected platforms (Apple Home, Google Home, Alexa) to ensure end-to-end communication works through the Matter bridge

[📷 Image Placeholder: Screenshot showing successful S2 inclusion with correct security class assigned in Z-Wave JS or similar platform]


Special Case: Migrating S2 Keys Using Z-Wave Network Backup

If you’re lucky enough to have a bridge and controller that support proper Z-Wave network backup/restore with S2 key transfer, this method preserves everything without re-inclusion.

Compatible Backup Methods

Not all backup methods preserve S2 keys. Here’s what works:

MethodS2 Keys Preserved?Notes
Z-Wave JS NVM Backup✅ YesMust be same chip type (500→500 or 700→700)
Silicon Labs PC Controller✅ YesRequires matching SDK versions
SmartThings Hub Backup❌ NoS2 keys stripped from backups
Hubitat Z-Wave Backup⚠️ PartialWorks for 700-series only
Manual NVM extraction✅ YesAdvanced — requires technical knowledge

How to Transfer S2 Keys via NVM Backup (Z-Wave JS)

If both your old controller and new Matter bridge use 700-series or 800-series Z-Wave chips:

  1. In Z-Wave JS on your old controller, go to Driver → Backup NVM
  2. Save the backup file (it contains all network keys, including S2)
  3. On your new Matter bridge, ensure Z-Wave JS is configured but no devices are included yet
  4. Go to Driver → Restore NVM and upload the backup file
  5. Restart the Z-Wave network on the bridge
  6. Wait 5-10 minutes for all devices to be re-discovered with their existing security keys

⚠️ Critical Warning: NVM restore completely overwrites the target controller’s Z-Wave network. Only do this on a fresh/empty bridge. And never restore a 500-series backup onto a 700-series chip — it will corrupt the network.

[📷 Image Placeholder: Step-by-step screenshots of the NVM backup and restore process in Z-Wave JS]


Troubleshooting: What to Do When Standard Fixes Don’t Work

Sometimes you follow every step perfectly and things still don’t work. Here’s what to try next.

Problem: Device Includes But Falls Back to S0

Symptoms: The device pairs successfully, but the security class shows S0 instead of S2.

Causes:

  • DSK PIN was not entered or entered incorrectly
  • The device firmware doesn’t support S2 (check the manufacturer’s specifications)
  • The inclusion happened too quickly and the S2 negotiation timed out

Fix:

  1. Exclude the device
  2. Move it closer to the bridge (within 1 meter)
  3. Re-include, and this time enter the DSK PIN immediately when prompted — you typically have only 10-15 seconds
  4. If the device truly doesn’t support S2, S0 is acceptable but be aware of the security limitations

Problem: Device Includes With “No Security”

Symptoms: Security class shows “None” — commands work for non-secure devices but locks and security devices won’t function properly.

Fix:

  1. Exclude and factory reset the device
  2. Check that your bridge firmware supports S2 security
  3. Re-include with the device physically next to the bridge
  4. Ensure you’re not accidentally clicking “Skip” when the DSK prompt appears

Problem: Device Works Initially Then Goes Offline

Symptoms: Everything seems fine after inclusion, but the device stops responding after a few hours or days.

Causes:

  • S2 nonce synchronization failure (the rolling security counters get out of sync)
  • Z-Wave network congestion causing security timeouts
  • The device’s S2 implementation has a known firmware bug

Fix:

  1. Check for device firmware updates from the manufacturer
  2. Perform a “refresh” or “re-interview” of the device in your Z-Wave controller (this re-syncs the security counters without requiring re-inclusion)
  3. If the problem persists, exclude and re-include the device

Problem: “S2 Key Exchange Failed” During Inclusion

Symptoms: The inclusion starts but fails with a key exchange error.

Fix:

  1. Check the DSK label — make sure the PIN is readable and you’re reading the correct 5 digits (the first 5 digits of the full DSK)
  2. Try a different inclusion method — some bridges support QR code scanning instead of manual PIN entry, which is more reliable
  3. Reduce Z-Wave network traffic during inclusion — pause automations, stop polling, and exclude unnecessary devices temporarily
  4. Check for Z-Wave firmware updates for your bridge’s Z-Wave chip

[📷 Image Placeholder: Table or infographic summarizing common problems, their symptoms, and quick fixes]


Real-World Experience: My Full Migration Story

Let me share what actually happened during my migration to give you realistic expectations.

The Setup

  • Old system: SmartThings v3 hub with 23 Z-Wave devices (mix of 500 and 700 series)
  • New system: Home Assistant Yellow with SkyConnect + Z-Wave JS, connected to Matter
  • Devices: 2 Yale locks, 4 Zooz sensors, 6 Inovelli switches, 3 Aeotec multisensors, 5 GE dimmers, 2 Fibaro modules, 1 Ring Range Extender

What Went Wrong

I made the classic mistake: I tried to use the Z-Wave JS migration tool to transfer everything at once. The NVM backup from SmartThings didn’t include full S2 key data (SmartThings strips this for security). So after the restore:

  • Both Yale locks: Completely unresponsive — S2 Access Control keys were missing
  • 4 Zooz sensors: Showed as included but wouldn’t report data — S2 Authenticated keys corrupted
  • The rest: Mixed results — some worked on S0, some had no security at all

How I Fixed It

Phase 1 (Evening 1): I excluded and re-included all non-security devices (switches, dimmers). This was straightforward — about 15 minutes per device including parameter reconfiguration. I didn’t need S2 for these, so S2 Unauthenticated worked fine.

Phase 2 (Evening 2): I tackled the sensors. Factory reset each one, had the DSK PINs ready (I’d photographed them during installation — thank goodness), and re-included them one by one with S2 Authenticated. Two of the Aeotec sensors needed firmware updates before S2 would negotiate properly.

Phase 3 (Evening 3): The locks. This was the hardest part. I had to:

  1. Remove each lock from the door (to access the reset button and DSK label)
  2. Factory reset (which erased all user codes)
  3. Re-include with S2 Access Control (with the lock physically next to the hub)
  4. Re-mount the lock
  5. Re-program all user codes

Total time: About 12 hours spread over three evenings. Not fun, but everything works perfectly now — and the Matter integration means I can control everything from Apple Home, Google Home, and Home Assistant simultaneously.

What I’d Do Differently

  • Photograph every DSK label before installing devices in hard-to-reach places
  • Keep a device configuration spreadsheet updated from day one
  • Migrate in phases, not all at once — start with non-critical devices
  • Never trust automatic backup/restore to handle S2 keys across different controller manufacturers

Preventing S2 Key Mismatches in Future Migrations

Learn from the collective pain of the smart home community. Here’s how to set yourself up for painless future migrations.

Best Practice 1: Maintain a Device Documentation System

Create and maintain a living document with:

  • Every device’s DSK (full 40-digit code)
  • The 5-digit PIN for each device
  • Current security class
  • Firmware version
  • Z-Wave chip generation (500, 700, or 800 series)
  • Physical location
  • Custom parameters configured

Best Practice 2: Use Same-Generation Z-Wave Chips

When choosing a Matter bridge, match the Z-Wave chip generation to your existing controller:

  • 500-series → 500-series (NVM backup compatible)
  • 700-series → 700-series (NVM backup compatible)
  • 700-series → 800-series (usually compatible — check documentation)
  • 500-series → 700-series (NVM backup NOT compatible — manual re-inclusion required)

Best Practice 3: Regular NVM Backups

Schedule monthly NVM backups of your Z-Wave network. Store them securely. If your controller dies, you’ll have a recent backup with all S2 keys intact.

Best Practice 4: Buy Devices With QR Code DSK Labels

Newer Z-Wave devices include QR codes that contain the full DSK. These are:

  • Easier to scan than reading tiny printed numbers
  • Less prone to entry errors
  • Faster during inclusion
  • Can be photographed and stored digitally

[📷 Image Placeholder: Example of a Z-Wave device QR code/DSK label and where to typically find it on common device types]


S2 Security Classes and Matter: How They Map Together

Understanding how Z-Wave S2 security translates through a Matter bridge helps you troubleshoot end-to-end issues.

The Translation Layer

When a Z-Wave device communicates through a Matter bridge to platforms like Apple Home or Google Home, the security works in layers:

text[Z-Wave Device] ←→ S2 Encryption ←→ [Matter Bridge] ←→ Matter Encryption ←→ [Smart Home Platform]

The Matter bridge handles the translation. It terminates the Z-Wave S2 connection on one side and establishes a Matter-secured connection on the other.

What This Means for You

  • S2 keys only matter between the Z-Wave device and the Matter bridge
  • Matter security is handled separately (and automatically) between the bridge and your smart home platforms
  • If S2 fails, the Matter bridge can’t communicate with the Z-Wave device, so the device appears unavailable in ALL connected platforms — not just one

Security Level Mapping

Z-Wave SecurityMatter EquivalentDevices
S2 Access ControlMatter with CASE SessionLocks, alarms
S2 AuthenticatedMatter with CASE SessionSensors, thermostats
S2 UnauthenticatedMatter with CASE SessionSwitches, dimmers
S0 LegacyMatter with CASE SessionOlder Z-Wave devices
No SecurityMatter with CASE SessionBasic devices

All Z-Wave security levels are “elevated” to Matter’s CASE (Certificate Authenticated Session Establishment) when crossing the bridge. So even S2 Unauthenticated devices benefit from Matter’s strong encryption on the platform side.

[📷 Image Placeholder: Visual diagram showing the dual-layer security architecture — Z-Wave S2 on one side, Matter encryption on the other, with the bridge in the middle]


Frequently Asked Questions (FAQ)

Can I migrate Z-Wave devices to a Matter bridge without losing my S2 security keys?

Yes, but only if both your old controller and new bridge use the same generation Z-Wave chip (both 700-series, for example) AND you use a proper NVM backup tool like Z-Wave JS. If the chips are different generations or the backup tool doesn’t preserve S2 keys, you’ll need to re-include each device manually.

What happens if I use my Z-Wave device without S2 security?

The device will still function, but commands won’t be encrypted. For switches and dimmers, this is a low risk. For door locks and alarm systems, this is a serious security vulnerability — anyone with a Z-Wave radio within range could potentially intercept or send commands. Always ensure locks use S2 Access Control.

Do I need to be physically near the device during S2 re-inclusion?

Yes. The S2 key exchange requires strong, reliable communication between the device and the controller. Keep the device within 1 meter (3 feet) of the bridge during inclusion. After successful inclusion, you can move it back to its normal location and the mesh network will handle communication.

I lost the DSK label on my device. Can I still include it with S2?

Possibly. Some manufacturers print the DSK on the packaging (check if you still have it). Others store it in their mobile apps if you registered the device. As a last resort, some devices allow S2 Unauthenticated inclusion without the DSK, but this won’t work for locks requiring S2 Access Control. Contact the manufacturer for a replacement DSK if needed.

Will a factory reset of my Z-Wave device erase its S2 capabilities?

No. A factory reset clears the stored network keys and returns the device to its default state, but it does not remove the device’s S2 capability. The device will be ready for a fresh S2 inclusion after the reset. However, a factory reset on a lock will erase stored user codes and access schedules.

Can I have some devices on S2 and others on S0 on the same Matter bridge?

Yes. Z-Wave controllers (including those in Matter bridges) support multiple security classes simultaneously. Each device negotiates its own security level during inclusion. However, be aware that S0 devices generate significantly more Z-Wave network traffic due to the less efficient S0 encryption protocol (each command requires three frames instead of one).

How long does S2 re-inclusion take per device?

For simple devices like switches and sensors, expect 2-5 minutes including the security negotiation. For complex devices like locks and thermostats, budget 10-20 minutes because you’ll need to re-configure device parameters, user codes, and verify full functionality.

Does the order of device re-inclusion matter?

Yes, it can. I recommend this order:

  1. AC-powered devices first (switches, plugs) — these act as Z-Wave repeaters and build your mesh network
  2. Sensors and battery devices second — they benefit from the established mesh
  3. Security-critical devices last (locks, alarms) — by this point, your mesh is strong and the S2 key exchange is more reliable

Final Thoughts: It’s Annoying, But It’s Worth Doing Right

I won’t sugarcoat it — resolving S2 security key mismatches after a Matter bridge migration is tedious. It requires patience, documentation, and sometimes physical access to devices you installed in inconvenient places two years ago.

But here’s the thing: getting the security right matters. Your smart lock is the last barrier between a stranger and the inside of your home. Your alarm system is worthless if its commands can be spoofed. S2 encryption exists for a reason, and cutting corners during migration puts your home at risk.

Take a weekend. Work through your devices methodically. Document everything. And when you’re done, you’ll have a properly secured, Matter-compatible smart home that works with every major platform — and you won’t have to touch it again until the next big protocol shift.

Which, knowing this industry, will probably be in about three years. But at least now you’ll know exactly what to do.


[📷 Image Placeholder: Clean infographic summarizing the complete migration workflow — from documentation through exclusion, reset, re-inclusion, and verification]