This post shows how to boot a Raspberry Pi with no monitor or keyboard attached, with Wi-Fi and SSH ready to use. The method I wrote up in 2018 (dropping a wpa_supplicant.conf into the boot partition) no longer works on current Raspberry Pi OS. Here is the current official procedure, updated for Raspberry Pi Imager 2.0.
What you'll learn
- What has changed since the 2018 procedure
- How to set Wi-Fi, a user and SSH in Raspberry Pi Imager when writing the card
- How to connect over SSH after first boot, and how to find the IP address if that fails
- How to enable SSH without Imager
What changed since 2018
| Item | 2018 procedure | Now |
|---|---|---|
| Writing the OS | Write the image with dd |
Write it with Raspberry Pi Imager |
| Wi-Fi settings | Put wpa_supplicant.conf in the boot partition |
Enter them in Imager's settings. Putting wpa_supplicant.conf in the boot partition doesn't work on Raspberry Pi OS Bookworm and later |
| Enabling SSH | Put an empty ssh file in the boot partition |
Enable it in Imager's settings (the ssh file method is still in the official documentation) |
The 2018 procedure is still available in "Headless WiFi Setup for Raspberry Pi Zero W (No Keyboard or Monitor)".
What you need
- A Raspberry Pi with built-in Wi-Fi (e.g. Raspberry Pi 5 (check on Amazon))
- A microSD card
- A computer (Windows / macOS / Linux) with Raspberry Pi Imager installed
Steps
The steps below come from the official Raspberry Pi documentation and the official Imager 2.0 announcement. Screen names follow the official documentation.
1. Choose the device, OS and storage
Start Imager and work through the screens in order.
- Device: your Raspberry Pi model
- OS: for headless use, the official documentation recommends Raspberry Pi OS Lite
- Storage: the microSD card to write to (leave Exclude system drives selected)
2. Set Wi-Fi, user and SSH under Customisation
Under Customisation you set the hostname, localisation, username and password, Wi-Fi and remote access, selecting Next after each one. For headless use, you must configure Wi-Fi (or wired Ethernet) and either SSH or Raspberry Pi Connect.
- Wi-Fi: the SSID and password of your network
- Remote Access: turn on Enable SSH. You can log in with password authentication (the password of the user you created in Imager) or public-key authentication
- Raspberry Pi Connect: since Imager 2.0 you can link the device to your Raspberry Pi Connect account while writing the card. Use this if you want to connect remotely with Raspberry Pi Connect instead of SSH
3. Write the card and boot
Select Write, put the microSD card into the Raspberry Pi and power it on. The settings you entered in Imager are applied on first boot.
4. Connect over SSH
From a terminal on your computer, connect using the username and hostname you chose in Imager.
ssh <username>@<hostname>.local
If the .local name can't be found (for example on a network without mDNS), connect by IP address instead.
ssh <username>@<ip address>
Without a monitor you can't check the IP address on the Raspberry Pi itself, so the official documentation suggests these methods:
- Look at the list of connected devices in your router's admin page
- Scan your network with
nmapfrom your computer - Use a network scanner app on your phone (such as Fing)
If you don't want to type a password every time, create a key pair on your computer and copy it to the Raspberry Pi.
ssh-keygen
ssh-copy-id <username>@<ip address>
Changing settings after writing the card
The Debian Trixie-based Raspberry Pi OS released on 24 November 2025 includes cloud-init, which applies the first-boot settings. When you write the card with Imager 2.0, three files are created in the boot partition: user-data, network-config and meta-data. According to the official blog, you can edit user-data or network-config after writing to change the user or network settings. Wi-Fi is configured in network-config like this (replace the values with your own):
network:
version: 2
wifis:
renderer: NetworkManager
wlan0:
dhcp4: true
regulatory-domain: "US"
access-points:
"SSID":
password: "your-wifi-password"
optional: true
Enabling SSH without Imager
The official documentation also covers the case where you write the image without Imager's settings. Create these two files in the boot partition (bootfs):
- An empty file named
ssh userconf.txt, containing a single line:username:encrypted-password
To get the encrypted password, run the following command on your computer and enter your password twice. The LibreSSL that ships with macOS doesn't support -6, so you'll need to install OpenSSL separately.
openssl passwd -6
Note: this post summarises the procedures in the official Raspberry Pi documentation and blog as of November 2026. I haven't run through every step end to end on my own hardware. Screen names and steps may change with Imager or OS updates.
Summary
On current Raspberry Pi OS you can't configure Wi-Fi by putting wpa_supplicant.conf in the boot partition. Instead, enter Wi-Fi, user and SSH settings under Customisation in Raspberry Pi Imager before writing the card, then connect with ssh <username>@<hostname>.local after it boots. To change settings after writing, edit network-config or user-data in the boot partition. Without Imager, create the ssh and userconf.txt files yourself.
If this post helped, share it on X (Twitter) — it means a lot.
App by the author of this blog
I made an iOS reading management app called My Bookstore. Simple bookshelf management — give it a try.
Related posts
- Headless WiFi Setup for Raspberry Pi Zero W (No Keyboard or Monitor) — the 2018 procedure
- SwitchBot API × Raspberry Pi 5: Automated Room AC Control [2026 Edition]
References
- Getting started with your Raspberry Pi (Raspberry Pi Documentation)
- Remote access (Raspberry Pi Documentation)
- A new Raspberry Pi Imager (Raspberry Pi News, 2025-11-24)
- Cloud-init on Raspberry Pi OS (Raspberry Pi News)
This post is part of an experiment in automated updates using Claude Code.
No comments:
Post a Comment