FINDING RASPBERRY IP ADDRESS WITHOUT DISPLAY USING NMAP AND LOGIN WITH PUTTY in windows

Photo of author

By Jackson Taylor

Home » Hardware » FINDING RASPBERRY IP ADDRESS WITHOUT DISPLAY USING NMAP AND LOGIN WITH PUTTY in windows

As an Amazon Associate we earn from qualifying purchases.

If your Raspberry Pi has no monitor, keyboard or mouse attached, you can’t just type hostname -I to see its address. The good news is that you don’t need a screen at all. Your Pi gets an IP address from your network when it boots, and you can discover it from a Windows PC with a free tool called Nmap. Once you have the address, you can log in over SSH using PuTTY.

This guide walks through the whole process: finding your computer’s own IP address, scanning the network for the Pi, and connecting. The video above shows the same steps. I originally wrote this on Windows 8, so menus may look a little different on Windows 10 or 11, but the commands are the same.

What you need

  • A Raspberry Pi that is powered on and connected to the same network as your PC, by Ethernet cable or Wi-Fi.
  • A Windows PC on that same network.
  • Nmap installed on the PC (free, from nmap.org).
  • PuTTY installed on the PC (free SSH client).
  • SSH enabled on the Pi. On Raspberry Pi OS you can enable it when writing the SD card with Raspberry Pi Imager, or by placing an empty file named ssh (no extension) on the boot partition of the card.

Give the Pi a minute or two to finish booting before you scan. If you scan too early, it won’t show up yet.

Hardware Hack

Stop Buying New Batteries for Your Tech

Electronics are expensive, but their power sources don't have to be. Discover the simple engineering trick to recondition dead batteries and bring your gadgets back to 100% capacity.

Watch the Free Video

Step 1: Find your computer’s IP address

Nmap needs to know which network to scan, so first check your own PC’s address. Open Control Panel → Network and Internet → Network and Sharing Center.

On other systems, this guide to finding your local IP address shows the same step for Windows, Mac and Linux, and the router IP lookup guide helps you find the gateway address of your network.

See also
Z - SOURCE INVERTER -SINGLE PHASE SIMULATION IN MATLAB - SIMULINK
Network details screenshot

Click on your connection (Ethernet or Wi-Fi) and then Details. You will see your computer’s IPv4 address. In my case it is 192.168.137.1, so the network I need to scan is the one that starts with 192.168.137 and covers addresses 192.168.137.0 to 192.168.137.255.

A quicker way is to open Command Prompt and type ipconfig. Look for the line called IPv4 Address under your active adapter.

Nmap screenshot

Step 2: Scan the network with Nmap

Open Nmap (or Command Prompt, if Nmap was added to your path during installation) and run the following command, replacing the numbers with the first three parts of your own address:

nmap -sn 192.168.137.0/24

Here is what it means:

  • -sn tells Nmap to only check which devices are online, without scanning their ports. This makes it fast.
  • 192.168.137.0/24 is the range to check. The /24 means all 256 addresses from 192.168.137.0 to 192.168.137.255.

When the scan finishes, you get a list of devices that responded. One of them is your Pi. In my case it was 192.168.137.157.

Result screenshot

How to tell which device is the Pi

On a busy network you may see several devices. A few tips to pick the right one:

  • Run the scan once with the Pi unplugged and once with it powered on. The address that appears only the second time is your Pi.
  • Run Command Prompt as administrator. Nmap can then show the MAC address and the vendor name, and Raspberry Pi boards usually show a Raspberry Pi vendor name.
  • Scan only for devices with SSH open: nmap -p 22 –open 192.168.137.0/24. Your Pi should be in that shortlist if SSH is enabled.

Your own PC and your router will also appear in the list. You can ignore those.

Sustainable Tech

Keep Toxic E-Waste Out of Landfills

Don't throw away your failing laptop, phone, or car batteries. Learn how to recondition them at home in just a few hours. It's better for the planet—and your wallet.

Learn How It Works

Step 3: Log in with PuTTY

Now that you know the address, you can connect:

  1. Open PuTTY.
  2. In the Host Name (or IP address) box, type the Pi’s address, for example 192.168.137.157.
  3. Leave the port at 22 and the connection type as SSH.
  4. Click Open. If PuTTY shows a security alert the first time, accept it. This only means the Pi’s key is new to your PC.
  5. Enter the username and password when asked.
See also
POWER FACTOR MEASUREMENT USING ARDUNO

On older Raspberry Pi OS images the default login was username pi and password raspberry. Newer images ask you to create a username and password when you prepare the SD card, so use the ones you chose. If you still use a default password, change it with the passwd command after logging in.

What to do after you are connected

Once you are in, you have a full command line on the Pi. From here you can update the system, install software or run scripts. If you prefer a desktop, you can set up a VNC server and view the Pi’s screen from Windows, or use Remote Desktop from Windows. To transfer files over FTP, you will need the same IP address you just found.

If you want to reach the board from outside your home network, read about controlling a Raspberry Pi behind a router.

Troubleshooting

The Pi doesn’t appear in the scan

Check that the Pi and the PC are on the same network and the same IP range. Wait a bit longer for the Pi to boot, check the power supply, and make sure the Ethernet cable is firmly connected or that Wi-Fi details were set up before first boot. Some networks, such as guest Wi-Fi, block devices from seeing each other.

PuTTY says "connection refused"

This usually means SSH is not enabled on the Pi. Put the SD card in your PC and add an empty file called ssh to the boot partition, or re-write the card with SSH turned on in Raspberry Pi Imager.

The IP address keeps changing

Most routers hand out addresses dynamically, so the Pi may get a different one after a reboot. You can set a DHCP reservation in your router for the Pi’s MAC address, or configure a static IP on the Pi itself.

FAQ

Can I find the Raspberry Pi IP address without Nmap?

Yes. You can log into your router’s admin page and look at the list of connected devices. You can also try ping raspberrypi.local in Command Prompt, which works on many setups if the Pi still uses its default hostname.

See also
H- BRIDGE SQUARE WAVE INVERTER SIMULATION

Is Nmap safe to use on my home network?

A -sn scan only checks which devices respond, and scanning your own network is normal. Only scan networks you own or have permission to test.

Why does my computer’s address end in .1?

That is common when your PC is sharing its internet connection with the Pi, as in my setup, or when the PC acts as the gateway. The network itself starts at .0, which is why the scan uses 192.168.137.0/24.

Do I need a monitor the first time I set up a Pi?

No. If you enable SSH and set up Wi-Fi or plug in Ethernet before the first boot, you can do the entire setup from your PC using the steps above.

Revive Your Dead Electronics

Got a drawer full of dead gadgets or a failing car battery? Instead of paying a premium for replacements, use this simple trick to easily recondition them right from home.

See How It Works