Guides

HomeKit setup code vs Matter setup code: what's the difference?

A HomeKit setup code is eight digits and Apple-only. A Matter code is eleven digits and works across ecosystems. Here is what really separates the two, and how to spot which one your accessory uses.

By

3 min read

Two accessories on the desk, two small labels, each with a string of digits and a QR code. One says HomeKit. One says Matter. They do the same job, getting the device paired, but they are not the same thing.

Here is the difference at a glance, then the detail that matters.

HomeKit setup code Matter setup code
Length 8 digits 11 digits (sometimes 21)
Written as XXX-XX-XXX XXXX-XXX-XXXX
Defined by Apple, in the HomeKit Accessory Protocol the Connectivity Standards Alliance
Works with Apple Home only any Matter platform: Apple, Google, Alexa, SmartThings, Home Assistant
QR code starts X-HM:// MT:

The digit count is the quickest tell

Count them. Eight digits, grouped three, two, three, is a HomeKit code. Eleven digits, grouped four, three, four, is a Matter code. There is a longer 21-digit Matter variant for devices that need a custom setup flow, but you will rarely see it on consumer kit.

Neither is a number you chose. Both are printed at the factory and fixed for the life of the unit.

One is Apple’s, one is everyone’s

A HomeKit code only means something to Apple Home. Type it into anything else and it is just digits.

A Matter code is a commissioning code for the Matter standard, which Apple, Google, Amazon, Samsung and others all implement. The same code adds the accessory to any of them. It also supports multi-admin, so once the device is on one platform you can add it to a second without unpairing, using a fresh code the first platform generates for you.

That is the practical split. HomeKit code, one ecosystem. Matter code, as many as you want.

The QR codes are not just the digits as a barcode

A HomeKit QR code is X-HM:// followed by nine characters of base-36, plus a short setup ID in plain text. It encodes the setup code and the accessory category, and not much else.

A Matter QR code is MT: followed by a short base-38 string. It carries the setup code, a discriminator to pick the right device out of several nearby, the vendor and product IDs, and a list of which radios the accessory is currently listening on. That last part is why Matter setup usually starts over Bluetooth and then hands the device its Wi-Fi or Thread credentials. The QR tells your phone how to reach the accessory in the first place.

Thread is not the dividing line here, by the way. HomeKit accessories can run over Thread too. Matter just made it standard equipment.

What the two codes have in common

More than you might expect.

  • Fixed at manufacture. You never set either one, and a factory reset does not change it.
  • Not your Wi-Fi password, and not a PIN you picked. A separate thing entirely.
  • Checked locally during pairing, so the accessory has to be in the room.
  • Both specifications ban the same dozen lazy codes: 000-00-000, 123-45-678, all-one-digit, and so on. A label showing one of those means something has gone wrong.

They also share a failure mode. Lose the label and there is no screen anywhere that reads the code back to you, in Apple Home or any other app. If that has already happened, see our guide to finding a lost setup code.

Which one is on your accessory

Look at the label and the box.

  • Apple’s HomeKit logo next to an eight-digit code: HomeKit.
  • The Matter logo, three arrows meeting at a point, next to an eleven-digit code: Matter.
  • Both labels present: the accessory does both, which is common on devices from the last couple of years.

New accessories increasingly ship Matter only. Older ones are often HomeKit only. If in doubt, count the digits.

Frequently asked questions

How can I tell a HomeKit code from a Matter code?
Count the digits. Eight digits written as XXX-XX-XXX, next to Apple's HomeKit logo, is a HomeKit code. Eleven digits written as XXXX-XXX-XXXX, next to the Matter logo, is a Matter code. The QR codes differ too: a HomeKit one starts X-HM:// and a Matter one starts MT:.
Can one accessory have both a HomeKit and a Matter code?
Yes. Some accessories speak HomeKit directly and Matter as well, so they carry both labels. Newer devices increasingly ship with only a Matter code, and older ones often have only a HomeKit code.
Is a Matter code more secure than a HomeKit code?
Not really. Both are one-time secrets checked locally during pairing, so the accessory has to be physically present, and both specifications ban the same list of trivial codes. The difference is reach, not strength: a Matter code works with more platforms, it is not harder to crack.
Do I still need the Apple Home app for a Matter accessory?
No. A Matter code can be used by any Matter controller, including Google Home, Amazon Alexa, SmartThings and Home Assistant. A HomeKit code only works with Apple Home.

Guides

Do you need the HomeKit setup code again after pairing?

In normal use, no. A paired accessory keeps working without the code. But a handful of situations bring it back, and Apple Home will not show it to you when they do.

2 min read

  • homekit
  • matter
  • setup-codes
  • pairing

Guides

Can you find your HomeKit setup code in the Apple Home app?

The Apple Home app never shows the setup code for an accessory you have already paired. Here is why, the one Matter exception that gets close, and where the real code lives.

3 min read

  • homekit
  • matter
  • apple-home
  • setup-codes
  • pairing

← All posts