English
Login

How to set a Static IP Address

Relevant for

MK4 family
XL family
MINI family
MK3.5 family
MK3.9 family
3 comments
Article is also available in following languages
English
Čeština
Polski
Deutsch
Français
Español
Italiano
日本語
This article is intended for experienced users only!

When using PrusaLink, you connect to your printer via its IP address, which is assigned to it by the DHCP server on your network. Sometimes, if your printer disconnects and reconnects, it may receive a different IP address from the DHCP server. This can cause connection issues if you're trying to access the printer using its previous IP address, which is no longer valid.

How to solve it?

Set your router's DHCP to consistently assign the same IP address to a device based on its MAC address.

The MAC address is available in the menu System > Network. Note that it differs for the Ethernet or the Wi-Fi.

This alone should be enough to prevent the IP address from changing over time.

In some specific network setups, you might want to set up your printer to use a static IP address instead of requesting to be given the IP Address from the DHCP server. 

In case of large networks, the chosen IP address should be outside of the DHCP range to avoid conflict of address.

To set a static IP address on the printer, you can enter the IP address, network mask, gateway, and specify the DNS server in the prusa_printer_settings.ini configuration file:

 

[eth::ipv4] 
type=static 
addr=192.168.0.42 
mask=255.255.255.0 
gw=192.168.0.1 

[network] 
dns4=1.1.1.1;8.8.8.8

 

 

Copy this file to a USB drive and upload it to the printer via the menu Settings > System > Load Settings from File. This will load all the settings from the .ini file. (Note, this is a different menu than "load settings" for Wi-Fi settings, which only uploads Wi-Fi data.) Afterward, restart the printer.

Be careful, you need to reserve the given IP address in the router's settings for the printer to avoid potential IP address conflicts.

For setting a static IP address for Wi-Fi instead of the Ethernet, the process is exactly the same, but instead of [eth::ipv4] use [wifi::ipv4].

 

Setting a Hostname

Alternatively, you can use a hostname (mDNS) to access PrusaLink instead of using the IP address. A custom hostname can be set up either through the printer’s menu Settings > Network > PrusaLink > Hostname or by adding it to the prusa_printer_settings.ini file:

[network]
hostname=dragan1

After editing and saving the file, load it using the menu Settings > System > Load Settings from File

Once configured, insert the hostname followed by .local into your browser (e.g., http://dragan1.local) instead of the IP address, and then log in. This eliminates the need to remember or manage IP addresses. 

Custom hostnames are supported by FW 6.1.2 or newer.
Note that hostnames might not work on some networks due to limitations in specific network configurations. 
 

3 comments

Log in  to post a comment
ciscokeb
Replaced the [eth::ipv4] with [wifi::ipv4] and followed the instructions. My problems SOLVED.If you want to avoid all the hype regarding DHCP and runing into a "duplicate IP" issue, set the last octet of your Static IP address to the high end. Example 192.168.2.254, Subnet 255.255.255.0. With 254 being the high end. Unless you have a CRAZY amounts of devices in your home using DHCP, you'll never hit 254.
That's my two cents worth. :)
 
Lefrom
Followed all the steps for WIFI, in the printer settings it changes from DHCP to STAT but addr, mask and gateway remains all in 0.0.0
Jeff Lastofka
I read this article, and then I just set my WiFi mesh router to assign fixed IP addresses to my MK4 and my XL. That seems to be enough. I didn't have to add anything to the printer files or settings. So it seems the instructions in this article are overly complicated, or maybe I'll find out later that just changing the router wasn't enough, but so far it's working fine.