How to Use Your Raspberry Pi as a Wi-Fi Extender (Full Setup)

If you click our links and make a purchase, we may earn an affiliate commission. Learn more

Before I spent money on yet another Wi-Fi extender, I thought, why not try using a Raspberry Pi? I gave it a shot, and honestly, I was surprised how simple it was to turn it into a signal booster. If you’ve got dead zones at home, this little project might fix them.

A Raspberry Pi can function as a Wi-Fi range extender by connecting to an existing router and rebroadcasting that signal, effectively extending the network’s coverage. This can be achieved using RaspAP for a simplified setup or through a manual configuration process for greater control.

If you’re ready to turn your Pi into a DIY range extender, keep reading. I’ll show you what hardware you need, how the network setup works, and two ways to make it run: one for beginners and one for tinkerers.

If you’re new to Raspberry Pi or Linux, I’ve got something that can help you right away!
Download my free Linux commands cheat sheet – it’s a quick reference guide with all the essential commands you’ll need to get things done on your Raspberry Pi. Click here to get it for free!

Raspberry Pi Wi-Fi Extender: Architecture and Setup Options

Before we begin, let us make sure we understand what we mean by Wi-Fi extender or repeater. A Wi-Fi extender is a device that connects to one of your Wi-Fi networks and then redistributes its signal to other devices.

The primary purpose of such devices is to extend the range of an existing Wi-Fi access point. You typically place such a device near the edge of your existing Wi-Fi range, and it can redistribute signals to extend Wi-Fi coverage.

There are several affordable and effective pre-built Wi-Fi range extenders available. For example, you can get this TP-Link Wi-Fi range extender for as low as $25.

For most one-off use cases, these pre-built Wi-Fi range extenders perform significantly better than the one we will build using a Raspberry Pi. So if you are primarily looking for a good, affordable option, I would recommend getting one of the pre-built ones.

However, if you want to do it as a project/ learning experience, making your own Wi-Fi range extender with a Raspberry Pi can be a fun way to understand how a Wi-Fi access point works.

How it Works

The key concept of creating a Wi-Fi range extender is relatively straightforward. We first connect our Raspberry Pi to an existing Wi-Fi access point. Then we set up a hotspot on our Raspberry Pi, so other devices can connect.

Prefer reading without ads and popups?
Members get an ad-free version of every guide, plus exclusive project support.
Join the Community | Sign In

While the theory is simple, several configuration steps are required on our Raspberry Pi for the network connection to work correctly.

Single vs Dual Radio (USB Dongle)

There are two hardware setups to achieve this:

  • Dual Radio: We use one antenna/chip to connect to the Wi-Fi access point (e.g., the onboard Wi-Fi of our Raspberry Pi) and a separate antenna/chip to create a hotspot/access point (e.g., a USB Wi-Fi dongle).
  • Single Radio: We use the built-in Wi-Fi antenna/chip on our Raspberry Pi for both connecting to an access point and initiating our own access point.

For most practical purposes, I recommend you go with the Dual Radio approach.

Although you can use a single chip for both connecting to a Wi-Fi access point and initiating your own hotspot, it will significantly bottleneck your network connectivity speed. The Single Radio approach can be used for prototyping and testing the method out.

But without an extra USB Wi-Fi dongle, connectivity speed will be significantly reduced:

You can see in the speed tests I ran that Dual Radio mode averages twice the download speed of Single Radio mode. I used Ookla Speedtest for these, using the same home Wi-Fi connection and placing them at the exact distances.

Requirements for a Raspberry Pi Wi-Fi Extender

But before we get started with setting up our Raspberry Pi Wi-Fi extender, there are a few things that we need to get ready:

  • Raspberry Pi: In this post, I have used a Raspberry Pi 400. The primary consideration when getting a Raspberry Pi for a Wi-Fi range extender is whether its Wi-Fi chip supports Access Point (AP) mode. Based on my research, all models after the Raspberry Pi 3B+ support simultaneous client and AP modes.

    However, if you are looking to purchase a new Raspberry Pi for this purpose, I would recommend the Raspberry Pi 5 starter kit or Pi Zero 2 W for its smaller form factor.
  • USB Wi-Fi Adapter: When searching for a USB Wi-Fi adapter for this project, ensure it supports Access Point (AP) mode and Linux or Raspberry Pi OS. Many Wi-Fi adapters have this support, even when it’s not officially listed.

    However, it would be wise to verify these things before purchasing. I personally used the TP-Link TL-WN725N adapter for this tutorial. Although I ran into a few issues because it didn’t support Access Point (AP) mode, I found workarounds. I also found this NETGEAR AC1200 Wi-Fi adapter that has AP mode, and some people on Reddit claim it is plug-and-play compatible with Raspberry Pi OS.
  • Power Supply: The performance of your Wi-Fi adapters depends heavily on the quality of your Power Supply. Therefore, when building a Wi-Fi range extender, I would highly recommend using an official Raspberry Pi Power Adapter.
  • The Usual Stuff: Make sure you have the things needed to run a Raspberry Pi, such as an SD Card, an SD Card Reader, and Raspberry Pi Imager installed on a PC. Also, I would recommend using a dedicated display, keyboard, and mouse for your Raspberry Pi for this tutorial, since you’ll be switching network managers frequently, and SSH can get a bit tricky.

RaspAP vs Manual Setup

There are two methods we can use to turn our Raspberry Pi into a Wi-Fi range extender. We can either flash the RaspAP image to our SD Card and configure it to turn it into a Wi-Fi range extender. Alternatively, we can configure the default Raspberry Pi OS for this task.

While the first method is more straightforward, RaspAP has some limitations. Most of the advanced functionality and configurations are behind a paywall.

For example, features such as Wi-Fi repeater mode (single-radio mode) and Wireless LAN routing are only available to insiders.

We will cover both methods in this tutorial, and you can choose whichever suits you best.

Method 1: Using RaspAP

RaspAP is a Debian-based Linux distribution that turns your Raspberry Pi into a Wi-Fi router. By default, it is intended to be used as a full router: connect the Raspberry Pi to the internet via its Ethernet port and create a hotspot using its built-in Wi-Fi adapter.

However, by using an external USB Wi-Fi dongle and making some configuration changes, we can turn it into a simple Wi-Fi range extender.

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

Download & Install RaspAP

The first thing we need to do is download the latest RaspAP image. You can download the image from the quickstart page of their website. At the time of writing this tutorial, the newest version was based on Linux kernel version 6.12.

Once you have downloaded the image file, you can install it using the Raspberry Pi Imager, Balena Etcher, or another suitable software.

I highly recommend using Raspberry Pi Imager. With Raspberry Pi Imager, it is much simpler to set custom initial settings, such as username and hostname. Have a look at this tutorial on how to use Raspberry Pi Imager to install a custom OS and apply customization settings.

We need to apply customization settings so that we can easily SSH into our Raspberry Pi post installation (it will be required for a bug fix).

Once flashing is complete, you can insert the SD card into your Raspberry Pi and boot from it.

First Boot

Once you boot your SD Card, you will see a command-line interface if a local monitor is connected. However, if you are running in headless mode, wait 2 to 3 minutes, and you will see a new Wi-Fi access point with SSID RaspAP.

You can connect to this Wi-Fi network from your PC using the password “ChangeMe.

Once you are connected, you can access the dashboard by opening any web browser and navigating to this address:
http://10.3.141.1

You will be prompted to log in at this screen.

You can log in with username “admin” and password “secret“.

Once you log in, you will be taken to the RaspAP dashboard screen.

Configuration

As you can see from the dashboard, since we had our Wi-Fi dongle pre-installed in the system (before boot), it was automatically detected, connected to our home Wi-Fi, and used the onboard radio chip in hotspot/access point mode.

If your RaspAP is not connected to your home Wi-Fi, you can manually connect it by navigating to the Wi-Fi client section.

Here is a list of all available Wi-Fi connections. You can first add the connection and then connect to it.

To verify that your RaspAP is connected to the internet, you can navigate to the Networking tab.

From here, you can see that we have internet access through our wlan1 interface (Wi-Fi dongle).

There are several things you can configure in your RaspAP. However, for most purposes, it works right out of the box. Therefore, we will opt not to divulge its detailed configuration.

You can explore all the available configuration options by reading their documentation.

No Internet Connectivity Bug Fix

If, like me, you run into a strange bug where your Raspberry Pi is connected to the internet, and your PC is connected to your RaspAP access point, but your PC can still not access the internet, then worry not, because I found the fix to this bug as well.

I encountered this bug and had to dive under the hood to understand the issue. We can access the RaspAP command line prompt via SSH (which is why I recommended using Imager earlier).

It turns out this problem is caused by RaspAP not properly setting up NAT rules. In theory, RaspAP should automatically detect your uplink interface, assign a subnet to the access-point interface, enable IP forwarding, and install the NAT rules needed to route traffic from the hotspot to the internet.

However, this only works reliably when the Pi has a single Wi-Fi interface (typically wlan0) and RaspAP itself controls the entire networking stack. When you attach a second Wi-Fi adapter, RaspAP may not correctly identify which device should act as the uplink and which should serve the access point.

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

Therefore, it configures the access point correctly, but never creates a working NAT/MASQUERADE rule to forward packets from the AP network to the internet. Clients can join the hotspot and obtain an IP address, but their traffic simply stops at the Raspberry Pi.

Although the developers of RaspAP have implemented the Wireless LAN Routing feature to fix these kinds of issues. However, this feature is only available to RaspAP Insider subscribers.

To fix this issue manually, you need to SSH into your Raspberry Pi and follow these steps:

  • First, verify that this is the root cause of your issue using this command:
    sudo iptables -t nat -L POSTROUTING -v
  • If you see a response like this, then your NAT rules are not set up correctly:
  • To manually set up your NAT rules, enter these four commands in succession:
    sudo iptables -t nat -A POSTROUTING -o wlan1 -j MASQUERADE
    sudo iptables -A FORWARD -i wlan0 -o wlan1 -m state --state RELATED,ESTABLISHED -j ACCEPT
    sudo iptables -A FORWARD -i wlan1 -o wlan0 -j ACCEPT
    sudo netfilter-persistent save

  • Now you can confirm that your NAT rules are correctly set using this command again:
    sudo iptables -t nat -L POSTROUTING -v

As soon as you fix the NAT rules, you should see network connectivity established.

RaspAP provides a fast, user-friendly approach to building a Wi-Fi extender, especially when using two Wi-Fi adapters. Most of the configuration is handled automatically, and after applying a minor NAT routing fix, the system becomes fully functional.

With this complete, we can now move on to the manual method for users who prefer more control.

Quick note: If you find it hard to remember all these commands, I’ve put them all on a one-page cheat sheet. You can download it for free here so you have it handy whenever you're working on a project.

Method 2: Manual Setup (Advanced User)

In this method, we will learn how to manually set up our Raspberry Pi OS as a Wi-Fi range extender by installing the required programs and configuring them.

You can start with any OS. For this tutorial, we chose to start with the latest version of Raspberry PI OS (trixie). Consult this tutorial for installing Raspberry Pi OS Trixie on your Raspberry Pi.

Alternatively, if you are already running Bookworm, consult this guide to upgrade from Bookworm to Trixie.

Getting Everything Ready

Before doing anything else, make sure your Raspberry Pi is up-to-date using the command:
sudo apt update && sudo apt full-upgrade

Now we first need to understand the layout of our system. For this, we first need to understand all the interfaces that we have available. We can see a list of all the interfaces available to us using the command:
ip -br link | grep -E 'wl|eth'

As you can see, we had our Wi-Fi dongle plugged into the system, and it shows up as wlan1.

If you do not see your Wi-Fi dongle here, try unplugging and replugging it, or consult the dongle’s OEM to see if it requires any specific drivers.

Next, we need to check which of our interfaces support AP mode. To do this, first run this command to list all Wi-Fi devices:
iw dev

Now run this command for each device:
iw phy <device name> info

Scroll through the output and verify that the AP is listed in the “Supported interface modes” section.

For me, the default Wi-Fi interface (wlan0) supported the AP mode. However, the Wi-Fi dongle (wlan1) did not support AP mode. So I decided to use the onboard wlan0 as the hotspot AP and the wlan1 to connect to my local Wi-Fi.

Now let us install all the requisite softwares for this using the command:
sudo apt install dhcpcd5 hostapd dnsmasq iptables-persistent

Enable the dhcpcd and hostapd services using the commands:
sudo systemctl enable --now dhcpcd
sudo systemctl unmask hostapd
sudo systemctl enable hostapd

Before we go ahead with the rest of the tutorial, there is one additional setting we need to change. We need to set the WLAN country correctly in raspi-config. In raspi-config, navigate to Localisation Options -> WLAN Country and configure it according to your location.

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

Most of the services that we will enable, configure, and run are managed by systemd. Therefore, I highly recommend that you become well-versed in systemctl to debug and resolve any issues that may arise.

Configure Static IP for AP Interface

Before we configure our AP Interface (wlan0), we need to ensure Network Manager stops managing it (since we will manually configure it with dhcpcd).

To do so, we first need to ensure our Raspberry Pi is connected to our home Wi-Fi via the wlan1 interface, so we can continue SSHing into it while we configure. To check which wireless device is connected to your home Wi-Fi, use this command:
iwconfig

Luckily for us, wlan1 was connected to our home Wi-Fi. This is how we wanted it.

If you have the wrong adapter connected to your home Wi-Fi (i.e., the adapter you want to use for AP mode), you need to change it. To learn how to manage network connections, consult this guide on the nmtui tool.

Now we can tell Network Manager to stop managing our wlan0 interface by making a configuration file using these commands sequentially:
sudo mkdir -p /etc/NetworkManager/conf.d
echo -e "[keyfile]\nunmanaged-devices=interface-name:wlan0" | sudo tee /etc/NetworkManager/conf.d/unmanaged.conf

Now we can restart the Network Manager using the command:
sudo systemctl reload NetworkManager

Verify the changes using the command:
nmcli dev status

Now we can configure a static IP for our wlan0 interface by editing /etc/dhcpcd.conf file. Add this to the bottom of this file (you can set any IP you want).

Save and close this file. Now restart the dhcpcd service using the command:
sudo systemctl restart dhcpcd

Now, verify that the IP has been assigned correctly:
ip a show wlan0

If you are having trouble with dhcpcd not assigning the correct IP for your interface, you can use this command to assign the IP manually:
sudo ip addr add 10.3.141.1/24 dev wlan0

Configure HOSTAPD (AP Device)

Next, we need to configure hostapd to enable the AP mode on our wlan0 interface. We have an in-depth tutorial on turning your Raspberry Pi into an access point. Here I will only guide you through the basics.

First, we need to edit /etc/hostapd/hostapd.conf file. Add these lines to the file:

country_code=US           # change to your code
interface=wlan0
driver=nl80211
ssid=PiExtender
hw_mode=g                 # 2.4 GHz
channel=6                 # try 1/6/11
ieee80211n=1
wmm_enabled=1
auth_algs=1
wpa=2
wpa_key_mgmt=WPA-PSK
wpa_passphrase=StrongAPpassword123
rsn_pairwise=CCMP

Change the country code, SSID, and password to your preferences.

Now point hostapd to this configuration file using the command:
echo 'DAEMON_CONF="/etc/hostapd/hostapd.conf"' | sudo tee /etc/default/hostapd

Restart the hostapd service using the command:
sudo systemctl restart hostapd

Verify the changes have taken effect:
sudo iw dev wlan0 info

You will also see your Wi-Fi network in the list of available Wi-Fi networks on your PC.

However, don’t connect to it yet. We first need to configure DHCP, DNS, and NAT rules to ensure proper internet access.

Configure DNSMASQ (DHCP + DNS)

Now, let us configure DHCP and DNS for our AP interface. The DHCP server assigns IP addresses to devices that connect to your Wi-Fi, and the DNS server translates human-friendly hostnames to their corresponding IP addresses.

To set these up, we need to modify/etc/dnsmasq.conf file. Before editing it, first let us back up the default configuration using the command:
sudo mv /etc/dnsmasq.conf /etc/dnsmasq.conf.backup

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

Now, create and edit the /etc/dnsmasq.conf file and add this configuration to it:

interface=wlan0
bind-interfaces
listen-address=10.3.141.1
dhcp-range=10.3.141.50,10.3.141.150,255.255.255.0,24h
domain-needed
bogus-priv
server=8.8.8.8
server=1.1.1.1

Here, we are telling our Wi-Fi extender to assign IP addresses between 10.3.141.50 and 10.3.141.150 to any clients that connect to it. Furthermore, we are setting up 8.8.8.8 and 1.1.1.1 as the default DNS for these connections.

Here, 8.8.8.8 is Google’s DNS, while 1.1.1.1 is Cloudflare’s DNS. These are two commonly used public domain name servers. You can use any other server over here as well.

Now, restart the dnsmasq service using the command:
sudo systemctl restart dnsmasq

Verify that it is active:
sudo systemctl status dnsmasq

To understand more about what a DHCP does and what different configuration files do, read this in-depth tutorial on how to use a Raspberry Pi as a DHCP server.

Enable Routing & NAT Rules

We are almost there; now we need to enable forwarding and set up NAT and forwarding rules to allow the two adapters to route the data correctly.

First, enable forwarding using these commands:
echo "net.ipv4.ip_forward=1" | sudo tee -a /etc/sysctl.conf
sudo sysctl -p

Now add NAT and forward rules using these commands (sequentially):
sudo iptables -t nat -A POSTROUTING -o wlan1 -j MASQUERADE
sudo iptables -A FORWARD -i wlan0 -o wlan1 -m state --state RELATED,ESTABLISHED -j ACCEPT
sudo iptables -A FORWARD -i wlan1 -o wlan0 -j ACCEPT
sudo netfilter-persistent save

You can verify your settings using the command:
ip route

Verify that the NAT rules are correctly configured using the command:
sudo iptables -t nat -L POSTROUTING -v

That is it, now you should be able to connect to the internet through your Raspberry Pi. You can place it at the edge of your existing home Wi-Fi network, and it will extend the network’s range.


🛠 This tutorial doesn't work anymore? Report the issue here, so that I can update it!

Want to connect with other Raspberry Pi fans? Join the RaspberryTips Community. Ask questions, share your projects, and learn from each other. Join now.

Bonus Method: Single Radio Mode

You can create a Wi-Fi range extender using only the Raspberry Pi’s onboard Wi-Fi chip. For this, you need at least a Raspberry Pi 3B+.

To achieve this, we need to create a separate AP interface (uap0). Then you can connect to your home Wi-Fi using your default interface (wlan0) via Network Manager, and generate a hotspot or AP on the uap0 interface.

To create a separate AP interface using systemd, create a uap0.service file using the command below:

sudo tee /etc/systemd/system/uap0.service >/dev/null <<'EOF'
[Unit]
Description=Create uap0 virtual AP interface
After=NetworkManager.service wpa_supplicant.service
Wants=NetworkManager.service

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/sbin/iw dev wlan0 interface add uap0 type __ap
ExecStart=/sbin/ip link set dev uap0 up
ExecStop=/sbin/iw dev uap0 del

[Install]
WantedBy=multi-user.target
EOF

Now, enable this using the command:
sudo systemctl enable --now uap0.service

Verify that the new interface exists using the command:
iw dev

Now, follow the same steps we followed previously for dual radio: you only replace uap0 with wlan0 as the AP interface, and replace wlan0 with wlan1 as the client interface. Just skip the steps where we stopped Network Manager from managing wlan0.

Keep in mind, tho, as I explained previously, the Single Radio Wi-Fi range extender gives significantly lower throughput (approximately half) of the Dual Radio Wi-Fi range extender.

Recommended Related Articles to Read:

Building your own Raspberry Pi Wi-Fi extender isn’t just a fun weekend project — it’s a great way to learn how wireless networking really works. Whether you choose the simplicity of RaspAP or the flexibility of the manual method, you’ll walk away with a deeper understanding of how routers, access points, and NAT work together.

And once everything is running, you’ll have a fully functional DIY extender you can place anywhere you need better coverage.

Whenever you’re ready, here are other ways I can help you:

Test Your Raspberry Pi Level (Free): Not sure why everything takes so long on your Raspberry Pi? Take this free 3-minute assessment and see what’s causing the problems.

The RaspberryTips Community: Need help or want to discuss your Raspberry Pi projects with others who actually get it? Join the RaspberryTips Community and get access to private forums, exclusive lessons, and direct help.

Master your Raspberry Pi in 30 days: If you are looking for the best tips to become an expert on Raspberry Pi, this book is for you. Learn useful Linux skills and practice multiple projects with step-by-step guides.

Master Python on Raspberry Pi: Create, understand, and improve any Python script for your Raspberry Pi. Learn the essentials step-by-step without losing time understanding useless concepts.

You can also find all my recommendations for tools and hardware on this page.

Similar Posts