Right now, I would suggest the ESP32 family… very well supported, lots of community, it’s quite a powerful MCU and you can find it for 3-5$ on Ali
Electronics
Projects, pictures, industry discussions and news about electronic engineering & component-level electronic circuits.
Rules
1: Be nice.
2: Be on-topic (eg: Electronic, not electrical).
3: No commercial stuff, buying, selling or valuations.
4: No circuit design or repair, tools or component questions.
5: No excessively promoting your own sites, social media, videos etc.
Ask questions in https://discuss.tchncs.de/c/askelectronics
ESP32 or Raspberry Pico, if you want something easy to use, reasonably feature full, easy to interface, inexpensive, and medium form factor.
ATTiny, if you are strapped for physical space and don't have anything super complicated to interface with. Also, really inexpensive. I like it for basic electronics projects where even a Pico would be overkill.
On the other extreme, if you need more complex software, then a Raspberry Pi Zero 2 is a great option. Fortunately, the supply situation for Raspberry Pi has been improving a bit, at last. Sometimes, it's nice to be able to use all sorts of high-level software libraries, and then you hit a limit with the ESP32s and Picos of this world.
You can also mix and match. A PiZero talking to a Pico is a great combo. A ESP32 and an ATTiny can also sometimes turn out to be the more pragmatic choice.
Oh, and if you need even more oomph, then I really like the Raspberry CM4. Lots of nice carrier boards to choose from. But that's really not a microcontroller, so might not fit OP's question.
There are plenty of other boards out there. But they frequently have poor support, or are released only for the vendor to immediately abandon them. Maybe fine for one-off projects, but I generally prefer to stick with designs that last for a couple of years. Much easier to support, if I need to revisit my project down the line.
Nowadays there's a plethora of options available for beginners. Heck, even PICs have dev boards available with built-in programmers, so you connect it to your computer using regular old USB cable and you can build away using Microchip toolchains. Depending on your comfort level of low-level C, I'd probably still stay away from PICs as a beginner.
There's Arduinos and all the numerous clones (cheaper, different features). The main benefit of Arduino ecosystem would be that it's really easy to find libraries and/or content on the internet that gets you real close to solving your problems without having to write too much code yourself.
And of course very cost effective ESP32 based offerings that excel at wireless usecases (WiFi, bluetooth).
Recently there's even more beginner friendly boards appearing using MicroPython where you don't even need a toolchain. You connect the board to your computer, it appears as a mass storage device, you drop your Python code on it... and that's it, the board runs the code when you disconnect from the computer.
Have a browse through Adafruit and Sparkfun stores to get an idea of all the possible (beginner friendly) boards out there.
Choosing a beginner microcontroller depends on various factors, from ease of use to the project's complexity. The ESP32 or Raspberry Pico are fantastic for their user-friendly nature, reasonable features, and cost-effectiveness. For space-constrained projects, the ATTiny is a go-to with its simplicity and low cost, perfect for basic electronic setups. When diving into more intricate software, the Raspberry Pi Zero 2 shines with its versatility and improved availability. Mixing and matching these, like a PiZero with a Pico, or an ESP32 paired with an ATTiny, can offer pragmatic solutions. However, for more robust power, the Raspberry CM4 stands out, although it's more board than a microcontroller. It's crucial to consider longevity and support when choosing, ensuring the design lasts and is easier to revisit in the future
3 years ago the obvious answer was Atmel AVR chips but they are still in short supply today. I think ESP32 is the answer today. They are shockingly powerful for the price. And they have built in wifi, bluetooth, and USB.