Super Cheap Ethernet for the Raspberry Pi

Introduction: Super Cheap Ethernet for the Raspberry Pi

About: I'm a software engineer by trade, but have a long-standing love of audio, music gear, and home-made electronics.

This Instructable shows how you can add an Ethernet interface to any Raspberry Pi computer, for the lowest possible cost. You can get a Pi Zero or Model A/A+ connected to the Internet, or add a second network interface to a Model B, for $5 or less. Because it's connected via the GPIO lines, it leaves the USB port free, and doesn't require any extra power supplies or hubs.

Step 1: Parts List

You'll need just two items here:

  • A Microchip ENC28J60 Ethernet module
  • 7 jumper wires (female-female type)

I found the module from a supplier on - a set of three cost all of $9 including shipping from China! There are plenty of other versions on Amazon, Banggood and elsewhere for similar prices - just search for "ENC28J60". Most have a 10-way header for connection, with the signal names printed on the PCB next to it.

The jumper wires I used were from, stock code SC12901, but again there are many alternatives.

You'll also need to ensure you're using a recent Raspberry Pi OS version. The instructions here were written using the Raspbian "Jessie Lite" distribution from February 2016. To be precise, you'll need a version with Device Tree support, which was added to Raspbian distributions at the start of 2015.

Step 2: Wiring Up

There are seven wires - two power, four SPI, and an interrupt line - to be connected between the Pi and the ENC28J60. It helps to plan which colour jumper wire you're going to use for each signal beforehand - you can use the suggestions below as a starter.

The PI GPIO header is described in detail at - for convenience I've reproduced the 40-pin version here. The ENC28J60 connections should be printed on the PCB itself.

Signals should be wired between the Pi and the ENC28J60 as follows:

Pi            ENC28J60     Colour
+3V3          VCC          Red
GPIO10/MOSI   SI           Green
GPIO9/MISO    SO           Yellow
GPIO11/SCLK   SCK          Blue
GND           GND          Black

GPIO25        INT          Blue
CE0#/GPIO8    CS           Green

If you've followed the suggested wire colours, the headers should look exactly like the photographs.

Step 3: Before You Turn It On!

If you've miswired it, chances are nothing bad will happen, unless you've got the power supply connections wrong! If you have a multimeter, check for continuity between the +3.3V supply (pin 1 on the Pi GPIO header) and the VCC terminal on the Ethernet module, and between GND (pin 39 on the Pi) and ground on the module.

(Image (c) NASA, from

Step 4: Configure the Software

If you're happy with the wiring, boot up the Pi and log in as usual.

The Linux kernel will now need to be configured to recognise the new device. If you're not familiar working with the command line, check out this introduction on the Raspberry Pi website.

First we'll do a quick check. At the command prompt, type

ls /boot/overlays/enc28*

If the Pi responds simply with


then you're good to go. If not (i.e. "No such file or directory"), the OS version is too old and you'll need to update it. These instructions assume you're using Raspbian "Jessie" release.

If all's well, type

sudo nano /boot/config.txt

This will start the nano text editor, editing the system configuration file /boot/config.txt.

Scroll down until you find a section starting # Uncomment some or all of these and enter the following two lines:


(For the first of these, if you can see a line #dtparam=spi=on, you can just remove the # character from the start of the line).

Save the file with Control-O Enter Control-X. (For the curious, there's a lot of information on config.txthere).

You can now reboot the system with

sudo /sbin/reboot

Step 5: Reboot and Test

Reboot the Pi, and log in again. Back at the command prompt, check the network configuration with


If all is well you can see something like this:

eth0      Link encap:Ethernet  HWaddr 9e:df:83:ec:38:91  
          inet addr:  Bcast:  Mask:
          inet6 addr: fe80::a74c:6e6b:de3f:11b2/64 Scope:Link
          RX packets:3756 errors:0 dropped:130 overruns:0 frame:0
          TX packets:207 errors:15 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:289970 (283.1 KiB)  TX bytes:27617 (26.9 KiB)

(On a Model B, you should of course now have both eth0 and eth1).

If this is working, check your Internet connection (e.g. ping and it's all done!


If you don't see any eth0 device, try one of the following troubleshooting tips:

  • Re-check the jumper wiring. All wires need to be connected correctly for the interface to function at all.
  • Check the link lights on the ENC28J60 module (and on the network hub where you plugged it in). Note that the module provides good old 10-Mbit half-duplex Ethernet; it's possible your hub isn't configured to expect this.
  • Check to see the driver module is loaded with:

You should see a line starting enc28j60 in the output. If not, re-check the /boot/config.txt contents.

  • Check for boot-time messages with the command:

You should see messages similar to the following when the driver starts up:

[   13.012797] spi spi0.0: setting up native-CS0 as GPIO 8
[   13.013115] spi spi0.1: setting up native-CS1 as GPIO 7
[   13.128148] enc28j60 spi0.0: enc28j60 Ethernet driver 1.01 loaded
[   13.187818] net eth0: enc28j60 driver registered

followed a short while later by:

[   18.684532] net eth0: link up - Half duplex
[   18.684755] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

4 People Made This Project!


  • Puzzles Challenge

    Puzzles Challenge
  • Rice & Grains Challenge

    Rice & Grains Challenge
  • Lamps Challenge

    Lamps Challenge



2 years ago

Hi! Many thanks for these instructions - I managed to bring the ENC28J60 to life on my Raspberry Pi Zero :-) Everything works just as described with Raspberry Pi OS.

I am now trying to get it to work with LibreELEC but I have not been successful so far. I have added the lines "dtparam=spi=on" and "dtoverlay=enc28j60" to /flash/config.txt but the device does not show up upon reboot. The device tree should be there ("ls
/flash/overlays/enc*" shows the ENC28J60) and some online posts indicate that it *should* work but for me it does not.

Did anyone get this device work on LibreELEC? Any tips on what I may be missing?


2 years ago

Still works, even with a 1A running buster lite.

Had a enc28j60 module from zero research which is only labeled numerically.
Pins are as follows (courtesy of )

Zero Research ENC28J60 Breakout
1. /CS
3. SI
4. SO
5. GND
6. /WOL
7. /INT
10. VDD

systemd .link file trick helped persist the mac address and I get consistent 3Mbps thtough iperf. More than sufficent for iot and ssh.


2 years ago

Works well. Only downside that I have noticed is MAC address changes after each reboot. Is there any way fixing it?


3 years ago

Thanks for the excellent post. I am building a similar setup but using this module (
Question is, I am not sure if RPI Zero 3v3 output is capable of delivering enough current for these modules? I see controversial opinions, such:

All Raspberry Pi since the Model B+ can provide quite a bit more, up
to 500mA to remain on the safe side, thanks to a switching regulator.

Still, you should generally use the 5v supply, coupled with a 3v3 regulator for 3.3v projects.

Can you advise on this point please?



Tip 4 years ago

If you would like to hardcode full duplex on raspbian (stretch) it is possible in /etc/network/interfaces by adding line to your eth config: (and don't forget to install ethtool from APT)

auto eth0
allow-hotplug eth0
iface eth0 inet static
address 192.168.1.X
gateway 192.168.1.Y
pre-up /sbin/ethtool -s eth0 speed 10 duplex full autoneg off # <--- this line

I hope it helps somebody :)

4 years ago

It's a great tutorial! Do you know if it's possible to add more than 1 ethernet module? For making a hub-type concentrator for an iot project, so speed is not essential


Reply 4 years ago

In theory you can... Just load the enc28j60-spi2.dto in the config.txt nad you can connect the device to the SPI2 interface pins. Should be in the 4.14.78 firmware.
I will be trying this out shortly as I need the the first SPI interface for a touch screen


6 years ago

Interesting, I didn't know that Rasbian Jessie already had a device tree overlay and a driver for the ENC28J60. Thanks for sharing!

Only disadvantage is that ENC28J60 has a 10 Base-T PHY, which means its theoretical maximum speed will be 10 Mbps. But, for projects where a second Ethernet interface is required and speed is not critical, it's a great low cost alternative. Especially since you can design you own custom PCBs using that chip and adding whatever features you want on them.


Reply 6 years ago

Yes, it's only 10Mbps, although the driver does a pretty decent job - I've been getting 350-400Kbytes/sec download speed over a broadband connection. It's plenty for very low-cost IoT-style applications, and perfectly tolerable for ssh access, software update, etc. I wouldn't recommend it for a webserver / file server, but then the Pi has mediocre disk speed anyway, and doesn't do very well even with 100Mbit Ethernet.