Halloween DealsAmazon USHalloween week deals: useful picks before month-endAmazon US: current deals, useful picks and tech finds.Check DealsClean PCRecommendedOne scan can reveal what keeps slowing WindowsLook for cleanup and repair opportunities.Run ScanHalloween DealsAmazon USOctober picks are moving - compare before checkoutAmazon US: current deals, useful picks and tech finds.See Picks×
FREEDOM251

Freedom251 › Blog › embedded development

How to Build a Matter Device with an ESP32-C6 and ESP-Matter

By Freedom251 Team · · 10 min read

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

You can build a working Matter device on an ESP32-C6 by installing a compatible ESP-IDF toolchain, adding ESP-Matter, selecting an example, setting the target to esp32c6, building and flashing the firmware, then commissioning it with a Matter controller. The C6 includes both Wi‑Fi and IEEE 802.15.4, so the same platform can run Matter over Wi‑Fi or Thread. The exact endpoints and commands depend on the product data model you choose.

What you need before starting

Use a development board supported by Espressif. The ESP-Matter guide specifically names the ESP32-C6-DevKitC-1 and ESP32-C6-DevKitM-1. You also need a USB data cable that matches the connector on the board you select. Connector choice is board-dependent, so choose the board first and the cable second.

As an Amazon Associate I earn from qualifying purchases.

Item Requirement Why it matters
Development board ESP32-C6 board such as ESP32-C6-DevKitC-1 or ESP32-C6-DevKitM-1 Provides the C6 chip, USB connection and accessible GPIOs for the example hardware.
USB cable Data-capable cable with the connector required by the selected board Provides power, firmware flashing and serial logs. A charge-only cable will not work for development.
Host computer Linux or macOS, or Windows using WSL for the documented ESP-Matter workflow Runs ESP-IDF, the build tools and commissioning utilities.
ESP-IDF toolchain Espressif’s RISC-V toolchain, CMake/Ninja and ESP-IDF libraries and scripts Compiles the application, bootloader and partition table for the C6.
Matter controller Host-based chip-tool, another supported Matter controller, or a RainMaker mobile application Commissioning is required before a controller can operate the device.

Have the board connected directly to the computer while developing. Hubs and charge-only cables can prevent the serial port from appearing or interrupt flashing.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Understand the software pieces

ESP-IDF is Espressif’s operating and build environment for the chip. It supplies the compiler, CMake/Ninja integration, SDK libraries, configuration system and the idf.py command-line tool. ESP-Matter adds the Matter device stack, examples and integration layers that run on top of ESP-IDF.

#1 Best Overall
Elebase USB to USB C Adapter for iPhone 18 Pro Max,USBC Car Charger Adapter | 4Pack Type C Female to A Male Cable Converter for Apple Duo 17 16 15 14 Plus,iWatch Watch 12 11 10,iPad 9 8 Air,Airpods 5 4
  • Read Before You Buy — No Video Output: These adapters support charging and USB 2.0 data transfer, but cannot transmit video signals. Except for standard USB webcams (which use USB data only), they are not compatible with HDMI/DisplayPort cables, video-capable USB-C hubs, or docking stations with video output.
  • Convert USB-A Ports to USB-C: Designed to connect USB-C earphones, cables, flash drives, card readers, and other USB-C accessories to standard USB-A ports. Plug-and-play with no drivers or software required.
  • Aluminum Alloy Housing: Built with a sturdy aluminum alloy shell that aids in heat dissipation and protects against daily wear and scratches. Designed to maintain a stable and secure connection.
  • Compact & Travel-Friendly: The ultra-compact design allows the adapter to stay plugged into your device without blocking adjacent ports or adding bulk, reducing wear and tear on your original USB ports.
  • 12-Month Warranty: Backed by a 12-month manufacturer warranty for peace of mind. Designed to meet strict quality control standards for reliable everyday performance.

Matter itself describes a product through a data model. Endpoints contain clusters, clusters expose attributes and commands, and the selected device type defines expected behavior. A light, switch, sensor and lock therefore require different endpoint and cluster arrangements even though they can all use the same ESP32-C6 hardware. Decide what the product is supposed to be before changing the example.

Choose an ESP-Matter installation route

There are two practical ways to prepare the development environment. Pick one route for a project rather than mixing files from unrelated releases.

Route Best for Trade-off
Host installation Developers who want ESP-IDF and ESP-Matter integrated with the local shell, editor and debugging tools. You install and maintain the compatible toolchain, ESP-IDF release and ESP-Matter dependencies yourself.
Official Docker image Reproducible setup or teams that want a prebuilt environment. USB and serial-port access must be passed through to the container, and editor integration can require extra configuration.
ESP-Matter component An application that already has an ESP-IDF project and needs the Matter component with a relatively small dependency footprint. Examples and some host utilities are not the central focus of this route.
Full ESP-Matter repository Learning from Espressif’s examples, using host tools, commissioning, certification and data-model development resources. The checkout is larger and includes more development infrastructure than a minimal application needs.

The Docker image bundles ESP-IDF, ESP-Matter and tools such as chip-tool and chip-cert. The repository route is usually the more useful starting point when you are following an example or need those host utilities. Whichever route you choose, pin a compatible release instead of silently tracking a moving “latest” checkout.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Prepare ESP-IDF on the host

Espressif separates installation from project development. Complete the installation for your operating system first, then load the ESP-IDF environment in every shell used for building.

  1. Install the supported prerequisites. Install the RISC-V compiler toolchain, CMake, Ninja and the ESP-IDF libraries and scripts using Espressif’s setup instructions for your operating system.
  2. Load the ESP-IDF environment. Use the export or activation script installed with ESP-IDF. Without this step, the shell may not find idf.py or the correct compiler.
  3. Check the selected release. Record the ESP-IDF and ESP-Matter release tags used by the project. Their compatibility and setup instructions can change as the documentation is updated.
  4. Confirm the command is available. Run idf.py in the activated shell and confirm that it responds rather than reporting an unknown command.

On Windows, the documented ESP-Matter path uses WSL. Docker is another supported option when you prefer not to install the complete stack directly on the host.

Get an ESP-Matter example

Start with an example whose device function resembles your intended product. Espressif lists Matter examples including Light and Light Switch. An example gives you a known-good application structure, commissioning flow and data-model starting point; it does not automatically define the final hardware behavior of your product.

  1. Obtain the ESP-Matter component or the full repository according to the route selected above.
  2. Open the chosen example’s directory, not the repository root unless its instructions explicitly require that.
  3. Read the example’s README and release notes before building. They identify any GPIO wiring, menu configuration, required controller options and release-specific commands.
  4. Connect the C6 board and identify its serial port. Port names differ by operating system and board revision.

Set the ESP32-C6 target and configure the project

From the example directory, select the C6 target with the command documented by ESP-Matter:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #2
Sale
Anker USB-C Hub, 5-in-1 USB Hub for Laptops, 4K HDMI Multiport Adapter | USB C Dongle with 90W Max Power Delivery, 3×5Gbps USB A Data Ports, for MacBook, Dell, and More (Charger Not Included)
  • 5-in-1 USB-C Hub: Experience comprehensive connectivity featuring a Power Delivery input, two USB-A 2.0 ports, a USB-A 3.0 port, and an HDMI port. (Note: The USB-C power delivery input port is only for connecting an external wall charger to power your laptop and cannot power peripheral devices.)
  • 90W Pass-Through Charging: Achieve optimal charging with 90W pass-through power to your laptop, supported by a total input of 100W, with the hub reserving 10W for operational efficiency. (Note: Wall charger not included.)
  • Quick Data Transfers: Accelerate your productivity with rapid data transfers using a high-speed 5Gbps USB 3.0 port and two 480Mbps USB 2.0 ports.
  • 4K HDMI Display: Enhance your visual experience with a hub capable of delivering 4K resolution at 30Hz in both mirror and extend modes. Please note that this hub is compatible with MacBook (macOS 12 and newer), Windows 10 and 11, ChromeOS, and laptops equipped with DP Alt Mode and Power Delivery. Note: This device is not compatible with Linux.
  • What You Get: Anker USB-C Hub (5-in-1, 4K HDMI), welcome guide, 18-month warranty, and our friendly customer service.
idf.py set-target esp32c6

This target selection changes the project configuration and ensures that ESP-IDF uses the C6’s RISC-V toolchain and chip-specific settings. If you switch later to another ESP32 family, run set-target again from the project directory.

Open the project’s configuration menu when the example requires options that are not enabled by default:

idf.py menuconfig

Use it to set application-specific options described by the example, such as commissioning behavior, logging or hardware pins. Do not copy GPIO numbers from a different board: the DevKitC-1 and DevKitM-1 expose different connectors and may require different wiring.

Build the firmware

Build from the configured example directory:

idf.py build

ESP-IDF compiles the application and its components, then produces the bootloader, partition table and application binaries. A successful build leaves those artifacts in the project’s build output directory. Compilation errors usually indicate an unactivated environment, an incompatible ESP-IDF/ESP-Matter combination, a missing dependency or an example-specific configuration problem.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

If the project was previously built for another target or release, remove stale generated files using the cleanup action documented for that ESP-IDF version, then run set-target and build again. Avoid copying a build directory between projects.

Flash the board and inspect logs

With the board connected, flash the generated images and open the serial monitor:

idf.py flash monitor

If more than one serial device is connected, supply the port option required by your operating system and the board’s actual port. The exact device name is different on Linux, macOS and Windows/WSL, so do not assume one path applies everywhere.

Rank #3
Sale
Anker USB C Hub, 7in1 Multi-Port USB Adapter, 4K@60Hz USBC to HDMI Splitter | 85W Max PD, 2 USB 3.0 & 1 USBC Data Ports, SD/TF Card Reader, for Laptops/Mac and Other Type C Devices (Charger Not Included)
  • Sleek 7-in-1 USB-C Hub: Features an HDMI port, two USB-A 3.0 ports, and a USB-C data port, each providing 5Gbps transfer speeds. It also includes a USB-C PD input port for charging up to 100W and dual SD and TF card slots, all in a compact design.
  • Flawless 4K@60Hz Video with HDMI: Delivers exceptional clarity and smoothness with its 4K@60Hz HDMI port, making it ideal for high-definition presentations and entertainment. (Note: Only the HDMI port supports video projection; the USB-C port is for data transfer only.)
  • Double Up on Efficiency: The two USB-A 3.0 ports and a USB-C port support a fast 5Gbps data rate, significantly boosting your transfer speeds and improving productivity.
  • Fast and Reliable 85W Charging: Offers high-capacity, speedy charging for laptops up to 85W, so you spend less time tethered to an outlet and more time being productive.
  • What You Get: Anker USB-C Hub (7-in-1), welcome guide, 18-month warranty, and our friendly customer service.

On reset, the monitor should show the application starting. Keep the monitor open while commissioning: it can reveal whether the device is advertising over BLE, waiting for a network, obtaining an address or reporting a data-model error. Exit the monitor using the key sequence documented by ESP-IDF for your terminal.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Commission the device

A freshly flashed Matter device is not yet part of a fabric. Commissioning transfers operational credentials and, for a Wi‑Fi or Thread product, supplies the information needed to join that network. ESP-Matter documents several routes.

Host-based chip-tool

chip-tool is useful for development because it runs from the host and exposes Matter commissioning and cluster commands directly. The ESP-Matter repository or Docker image includes the host utilities needed for this workflow. Use the pairing command syntax and argument order supplied by the version you installed; command details can change between Matter releases.

The documented pairing families include BLE-to-Wi‑Fi and BLE-to-Thread. A Wi‑Fi flow requires the network name and password. A Thread flow requires a Thread operational dataset and a commissioner capable of delivering it. In both cases, the device must be in its commissioning window and the controller needs the setup PIN and discriminator printed by the example or shown in its logs.

Manual setup code

If you have a numeric Matter setup code, choose the controller’s manual-code pairing flow. Enter the code exactly as displayed; transposed digits produce an authentication failure that can look like a radio problem.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

QR-code onboarding

When the example exposes a QR onboarding payload, scan it with a Matter controller that supports QR commissioning. Keep the board powered and within radio range until the controller reports completion.

RainMaker mobile applications

Espressif identifies its RainMaker mobile applications as commissioning and control options. This can be convenient for a phone-based demonstration, while chip-tool is generally better for repeatable host-side development and scripted checks.

Rank #4
Sale
UGREEN USB to USB C Adapter Combo 4-Pack, 10Gbps USB C Converter Space Gray | Data transfer & Fast charging for MacBook, iPhone 17/16/15, iPad, Samsung Galaxy, Apple Watch
  • Dual Converters, Infinite Potential:Includes 2× USB C male to USB A female adapters and 2× USB A male to USB C female adapters. Perfect for a wide range of uses—tablets with Bluetooth keyboards, expand USB ports on macbook, and more. Two different converters for all your daily needs
  • Next-Level 10Gbps & 3A Charging: No more slow 480Mbps, this usb to usb c adapter has a transfer speed of up to 10Gbps, allowing you to do more transferring in less time. This usb adapter fits both USB A and USB C charger, supporting up to 3A fast charging
  • Upgraded Exquisite Craftsmanship: With an aluminum alloy housing and metal connector, the usbc to usb adapter is extremely durable and sturdy. Rigorously tested to withstand more than 10,000 times of plugging and unplugging, ensuring long-lasting performance
  • Broad Compatible: The usb c to usb adapter widely supports all USB C/ USB A devices like laptops, tablets, cellphones, car chargers, and phone chargers. Such as compatible with MacBook Pro/Air 2023/2022, Thunderbolt 4/3 Devices,Apple MagSafe Watch 9/8/7/SE/Ultra, iPad Pro 2022/2021, Samsung Galaxy S23/S20/S10, and iPhone 17/16/15 Pro. Plug and play
  • Please Note: To reach 10Gbps speed, keep the cable under 3.3 ft. For USB A Male to USB C adapters, try flipping the USB C connector. USB C Male to USB A adapters support bidirectional 10Gbps transfer within 3.3 ft

Wi‑Fi or Thread: choose the transport deliberately

The ESP32-C6 supports both Wi‑Fi and IEEE 802.15.4, allowing Matter examples that use Wi‑Fi or Thread. Neither transport is universally superior.

Consideration Wi‑Fi Matter Thread Matter
Network infrastructure Uses the existing Wi‑Fi network and its credentials. Requires a Thread network and an operational dataset supplied during commissioning.
Commissioning input BLE onboarding can deliver the Wi‑Fi name and password. BLE onboarding can deliver Thread credentials when the commissioner supports the required flow.
Product fit Convenient when the product already expects Wi‑Fi coverage and mains power. Useful for low-power, mesh-oriented products where a Thread border router is available.
Testing requirement Test on the same network conditions expected by the product. Test with the intended Thread border router and dataset; a generic Wi‑Fi test cannot validate Thread behavior.

Select the transport in the example’s documented configuration and commissioning instructions. Do not infer the transport from the chip name alone.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Verify the application after commissioning

  1. Confirm fabric membership. The controller should report successful commissioning and assign a node identity.
  2. Check network attachment. For Wi‑Fi, verify that the device receives an address on the intended network. For Thread, verify attachment through the border router and the expected Thread dataset.
  3. Exercise the example’s function. A Light example should be tested through its documented lighting cluster commands; a Light Switch example should be tested through its switch behavior. Use the example’s data model rather than assuming every device accepts the same command.
  4. Watch the serial monitor. Look for application events, rejected commands, connectivity changes and resets while operating the device.
  5. Power-cycle and repeat. A device that works only immediately after flashing may have an initialization, persistence or commissioning-state problem.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Turn the example into a product

Product development should begin with the Matter data model, not with arbitrary GPIO code. Define the standard device type when one exists, then map the product’s behavior to endpoints and clusters.

Define endpoints and clusters

List every function the product exposes. A single-function lamp may need one endpoint with the clusters required by the selected Light device type. A combined product may need multiple endpoints, each representing a distinct controllable function. Keep endpoint identifiers, feature flags and attribute behavior consistent with the device type expected by controllers.

Connect the physical hardware

Replace the example’s simulated or fixed output with your LED, relay, sensor or other circuit. Verify voltage levels and board pin assignments against the selected C6 board documentation. Keep hardware access separate from Matter command handling so a transport change from Wi‑Fi to Thread does not require rewriting the product logic.

Configure commissioning and persistence

Set the product’s onboarding method, default behavior and storage requirements according to the example and release documentation. Test factory reset, re-commissioning and power loss. A device that cannot be reset reliably is difficult to develop and support.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Build a release process

Pin the ESP-IDF and ESP-Matter releases, record the board revision, preserve the configuration used to generate the binaries and test a clean checkout. Mutable “latest” documentation and container tags can change, so recheck compatibility before updating a production build.

Best Value
Sale
Anker USB C Hub, 5-in-1 USBC to HDMI Splitter with 4K Display | 85W Max PD, 1 Powered USB-C 5Gbps & 2 Powered USB-A 3.0 5Gbps Data Ports, for MacBook Pro, MacBook Air, Dell and More (Black)
  • 5-in-1 Connectivity: Equipped with a 4K HDMI port, a 5 Gbps USB-C data port, two 5 Gbps USB-A ports, and a USB C 100W PD-IN port. Note: The USB C 100W PD-IN port supports only charging and does not support data transfer devices such as headphones or speakers.
  • Powerful Pass-Through Charging: Supports up to 85W pass-through charging so you can power up your laptop while you use the hub. Note: Pass-through charging requires a charger (not included). Note: To achieve full power for iPad, we recommend using a 45W wall charger.
  • Transfer Files in Seconds: Move files to and from your laptop at speeds of up to 5 Gbps via the USB-C and USB-A data ports. Note: The USB C 5Gbps Data port does not support video output.
  • HD Display: Connect to the HDMI port to stream or mirror content to an external monitor in resolutions of up to 4K@30Hz. Note: The USB-C ports do not support video output.
  • What You Get: Anker 332 USB-C Hub (5-in-1), welcome guide, our worry-free 18-month warranty, and friendly customer service.

Troubleshooting common failures

idf.py is not found

The ESP-IDF environment is not activated in the current shell. Run the installation’s export or activation script, then retry. In a container, confirm that the command is being run inside the official ESP-Matter image rather than on the host.

The build selects the wrong chip

Run idf.py set-target esp32c6 from the example directory and rebuild. Delete stale generated output only with the cleanup procedure supported by your ESP-IDF release.

The board does not appear during flashing

Try a known data-capable USB cable, connect directly to the computer, check the board’s connector and identify the correct serial port. Close other programs using that port. A different DevKit revision may expose a different connector or port.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Flashing succeeds but no useful log appears

Confirm that the monitor is attached to the same port used for flashing and that the terminal baud setting matches the example’s instructions. Press the board’s reset button after opening the monitor.

Commissioning times out

Keep the device powered and near the commissioner, confirm that it is advertising, and verify the setup PIN and discriminator. For Wi‑Fi, check the network credentials. For Thread, verify that the commissioner has a valid operational dataset and a functioning Thread border router.

A controller cannot operate the device

Check that the controller is sending commands supported by the example’s endpoints and clusters. A Light Switch example is not interchangeable with a Light example merely because both use the same board. Inspect serial logs for rejected commands or endpoint mismatches.

A repeatable development checklist

  • Select an ESP32-C6 board and then obtain its matching USB data cable.
  • Install ESP-IDF’s RISC-V toolchain, CMake/Ninja and libraries, or use the official Docker image.
  • Choose the ESP-Matter component for a lean application or the full repository for examples and host tools.
  • Pin compatible ESP-IDF and ESP-Matter releases.
  • Open a Matter example and read its board and commissioning notes.
  • Run idf.py set-target esp32c6.
  • Configure required options with idf.py menuconfig.
  • Build with idf.py build.
  • Flash and monitor with idf.py flash monitor, supplying the actual serial port when needed.
  • Commission over BLE to Wi‑Fi or Thread, or use a manual code or QR code.
  • Verify the example’s endpoints and behavior with the matching controller commands.
  • Define and document the final product data model before replacing the example hardware logic.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

embedded developmentESP-IDFESP-MatterESP32-C6IoTMatterThreadWi-Fi

Leave a Reply

Your email address will not be published. Required fields are marked *

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Outdated Drivers Are Slowing You DownFree scan - exact matches

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.