Choosing a microcontroller for an IoT project: ESP32, Arduino or Raspberry Pi Pico
Choosing a microcontroller for an IoT project: how ESP32, Arduino boards and the Raspberry Pi Pico compare on radio, power, pins and toolchain.
This article covers what an IoT project needs from its board, how the three common families compare, and how to pick one for a first project. It does not cover single-board Linux computers as controllers, or industrial PLCs; those are different tools for different jobs.
Three names come up whenever someone starts a connected project: ESP32, Arduino and Raspberry Pi Pico. They overlap enough that beginners assume they are interchangeable, and differ enough that picking the wrong one costs a weekend. The difference comes down to three questions: does it have a radio, how much power does it need, and how comfortable is the toolchain for the kind of project you are building.
What an IoT project asks of a microcontroller
A microcontroller is a small computer on one chip: a processor, some memory, and a set of pins that can read voltages, drive outputs and talk to sensors over standard buses. It runs one program from the moment power arrives, with no operating system in the way. That is what makes it suitable for a sensor node: it starts instantly, draws little power, and does exactly one job.
An IoT project adds a requirement that older hobby projects did not have: the reading has to leave the board. That means either a radio on the board, a radio module attached to it, or a wired connection to something that has one. The radio decision drives most of the rest, because a radio costs power, memory and complexity, and the IoT protocols article explains what each radio commits you to above it.
The other things to weigh are: how many and what kind of pins you need (analog inputs, I2C and SPI buses for digital sensors, PWM outputs), how much memory your code and any network stack will need, how the board will be powered, and how you will program it. For a first project the last one matters most.
ESP32: Wi-Fi and Bluetooth built in
The ESP32 is a family of chips from one manufacturer (documented in the ESP-IDF programming guide), sold on many inexpensive development boards, with Wi-Fi and Bluetooth on the chip. That single fact is why it dominates hobby and small-scale IoT: a reading can go straight from the board to your network with no extra module.
The chips have a capable processor (dual-core on the classic parts, with single-core and RISC-V variants in the newer members of the family), enough memory for a full TCP/IP stack plus your application, and a generous set of peripherals. Newer variants such as the ESP32-C6 add Thread and Zigbee radios, which makes them a natural fit for Matter devices.
Power is the trade-off. With the radio active the chip draws far more than a microcontroller without one, and a board running continuously will not last on a small battery. The family has deep sleep modes that bring the draw down to a very small standby current, and a node that wakes, measures, sends and sleeps can run for a long time; the powering article explains how to budget that. Development boards also often include components (a USB-to-serial chip, an LED, a regulator) that draw current regardless, so a bare module on a custom board sleeps far better than a development board does.
The toolchain is broad. You can program an ESP32 with the Arduino environment and its libraries, with the manufacturer’s own framework in C, with MicroPython, or with a firmware project that needs no code at all and is configured from a text file. That last option is how a great many home sensors are built by people who never write a line.
Choose an ESP32 when the project needs Wi-Fi or Bluetooth, is mains powered or can sleep most of the time, and you want the widest range of examples to copy from.
Arduino boards: the simplest path
“Arduino” names both a company’s boards and the programming environment that runs on many boards, including the ESP32. Here it means the classic Arduino boards: simple 8-bit microcontrollers with a modest clock speed, a small amount of memory, and a beginner-friendly layout with clearly labeled pins.
Their virtue is that nothing is hidden. The program you write is close to the hardware, the board does exactly what the code says, and the sheer number of tutorials means almost any sensor has a wiring diagram and a sketch ready to copy. For learning how a sensor works, or for a project with no network at all, they remain the easiest start.
The limits are memory and connectivity. The classic boards have no radio; adding one means a shield or module and a library, and the small memory can struggle with a network stack. Newer boards from the same company include Wi-Fi and use more capable chips, which narrows the gap with the ESP32, at a higher price. Power draw at rest is low, and the simpler chips can be very frugal with careful code, but the development boards again include parts that undo some of that.
Choose a classic Arduino when the project is about sensing and control with no radio, when you are learning, or when you have a specific shield or library that only exists for it.
Raspberry Pi Pico: a fast core with flexible pins
The Pico is a small board built on a microcontroller designed by the Raspberry Pi organization (official documentation). It has a fast dual-core processor, more memory than the classic Arduino boards, and an unusual feature called programmable I/O: small state machines that can implement custom interfaces in hardware, which is valuable when you need to talk to something with an awkward protocol or drive many outputs with precise timing.
The base Pico has no radio. The wireless version adds Wi-Fi and Bluetooth through a separate module on the board, which brings it close to an ESP32 in capability, with a different toolchain and a different power profile. Later versions of the board added a more capable chip.
Programming is by C with the official SDK, or by MicroPython, which the board supports well and which makes it an easy first board for someone who already knows Python. The Arduino environment also supports it. Power draw at rest is moderate; the sleep modes are usable but the ecosystem for very low-power operation is less mature than the ESP32’s.
Choose a Pico when you want a fast, well-documented board with unusual I/O flexibility, when you prefer Python, or when the project is wired and the radio is not the point.
How to choose
| Question | ESP32 | Classic Arduino | Raspberry Pi Pico |
|---|---|---|---|
| Radio on the board | Wi-Fi, Bluetooth; Thread or Zigbee on some variants | None (newer boards: Wi-Fi) | None; Wi-Fi and Bluetooth on the wireless version |
| Processor and memory | Fast, ample | Slow, small | Fast, ample |
| Battery operation | Good with deep sleep; poor if always on | Good, especially with a bare chip | Moderate |
| Toolchain | Arduino, C framework, MicroPython, no-code firmware | Arduino | C SDK, MicroPython, Arduino |
| Special strengths | Radio built in, huge example base | Simplicity, learning | Programmable I/O, Python |
| Best first project | Wi-Fi sensor that reports to a controller | Sensor and display with no network | Timing-critical or Python-first project |
Two rules of thumb. If the reading has to leave the board over Wi-Fi, start with an ESP32 unless you have a reason not to. If there is no radio in the project, pick whichever board’s examples most closely match what you are building, because the tutorial you can follow is worth more than the specification you cannot use.
For a first project buy two boards, not one. Boards die from a wrong wire, a wrong voltage or a bad USB cable, and a second one turns a lost week into a lost hour.
When a microcontroller is the wrong tool
A microcontroller runs one program without an operating system. That is a strength for a sensor node and a weakness for anything that needs to store a lot of data, run several programs, serve a web interface with any complexity, or talk to a camera. Those jobs belong to a small Linux computer: a single-board computer with an operating system, storage and a proper network stack. The usual pattern is microcontrollers at the edge, doing the sensing on batteries, and one Linux box in the middle, doing the collecting, storing and displaying.
The other case is industrial. Where a device controls machinery, must meet safety requirements, or lives in a harsh environment, the answer is a PLC or an industrial controller with the certifications and the ruggedness that a hobby board does not have. A development board is for prototypes and for the many small jobs where nothing dangerous depends on it.
Within those limits, any of the three boards will carry a first IoT project to a working sensor on your network. The best one is the one whose tutorial you can finish this weekend.
Written by the IoT Crest editorial team. Facts in this article follow the editorial policy: only well-established behavior is stated and no figures are invented.