What is a bootloader? Explained simply
-
22. August 2025
What is a bootloader and why you need it
If you have ever flashed firmware onto a microcontroller, you have dealt with a bootloader—even if you may not have known it.
Whether it's Arduino, ESP32, STM32, or your PC at startup:
Nothing works without a bootloader.
But what exactly is a bootloader? What does it do—and why do you need it in almost every device?
What is a bootloader?
A bootloader is a small program that is started immediately after a microcontroller or computer is switched on.
Its task:
– Prepare the system,
– Load or start firmware,
– Optional: Enable updates.
In short:
The bootloader is the gatekeeper between the hardware and your actual application.
Without it, your code wouldn't run at all – or never be able to update.
What exactly does a bootloader do?
1. Initialization of the hardware
It activates, for example, memory, clock sources, or interfaces (UART, USB, etc.).
Depending on the system, it selects between internal and external memory.
2. Load or start firmware
The bootloader searches for the firmware (e.g., in flash, EEPROM, or SD card).
He checks their integrity (checksum, signature) if necessary.
He starts them using a so-called Jump
3. Enable firmware update
Many bootloaders allow firmware updates via USB, UART, WLAN, or SD card.
This is also called In-System Programming (ISP) or Over-the-Air-Update (OTA)
Example: Bootloader for microcontrollers
Arduino
The Arduino has a bootloader in its flash memory that listens briefly during reset:
Is there an upload via USB?
If yes → new firmware is flashed
If no → jumps to old firmware
ESP32
The bootloader decides, for example, whether to boot from the internal flash or from OTA partitions – important for updates.
He is also already doing clock and memory setup.
STM32
Has a built-in ROM bootloader – activated by specific levels at BOOT pins.
Alternatively: You can burn your own bootloader into flash (e.g., using the update function via UART, CAN, USB, etc.).
Tip for troubleshooting:
Many microcontrollers have multiple boot modes – e.g., “Normal Boot,” “Flash Erase,” “DFU Mode.” If your upload suddenly stops working, it is often due to the boot mode (or reset timing).
Why do you need a bootloader at all?
Because you don't want to externally delete and rewrite the flash every time
→ The bootloader remains permanently in memory and can receive new firmware.Because updates would otherwise be extremely costly
→ OTA, USB, SD – all of this is only possible with a bootloader that receives and writes the code.Because you sometimes need to manage different firmware versions
→ The bootloader can choose between multiple partitions or images.Because he “catches” errors
→ For example, a reset menu starts when the main firmware is not functioning.
Is it possible to work without a bootloader?
Yes – but:
You will then need a external programming device (e.g., ST-Link, J-Link, ISP programmer)
No OTA / no convenient update
More prone to errors during testing or updating
Conclusion: Okay for pure prototypes or very small projects.
For everything that needs to be updated later = Bootloader required.
What happens during flashing?
When uploading firmware, the following happens:
Bootloader (e.g. on the Arduino) recognizes the upload command
Old firmware is overwritten in memory
New firmware is transferred and checked in blocks
After flashing, the bootloader automatically jumps to the new code.
The flash area of the microcontroller is usually in sectors divided – one area is reserved for the bootloader, the rest for your firmware.
Conclusion
The bootloader is the first piece of software that runs when your device starts up – and ensures that your microcontroller actually Ready for use, updatable, and stable .
It often sits invisibly in the background, but without it you would be pretty much lost when developing, flashing, or updating.
If you really want to understand microcontrollers—and not just “upload” code—then you should know what a bootloader is and why it is so important.
FAQ – Frequently asked questions
What is a bootloader, explained simply?
A small program that starts when a microcontroller is switched on and ensures that your actual firmware is loaded and executed.
Is a bootloader firmware?
No – the bootloader is not the firmware, but rather the ‘starter’ or “loader” for the firmware. It is often stored in the reserved flash area.
Can you delete a bootloader?
Yes – with a complete flash erase. After that, you will need an external programming device to install a new one.
Why do you need a bootloader?
For example, for simple firmware updates via USB, UART, or OTA—without having to unscrew the device or control it in any special way.
What happens if the bootloader is damaged?
Then the device can no longer be booted. You need a programming device to restore it (e.g., ST-Link, USBasp, etc.).
