DHCP reservation - Adam-Cervenec/ESP32-Wake-on-Lan GitHub Wiki

How to Make Your Device Static on LAN

There are generally two ways to assign a static IP address to your device:

  • On the router (recommended โ€“ ensures consistency for all devices)
  • Directly on the device (Linux/Windows)

On the Router

This method varies depending on your routerโ€™s brand and firmware.

Most Common Approach

  1. Open your routerโ€™s web interface in a browser (usually 192.168.1.1 or 192.168.0.1).
  2. Log in:
    • Default login is often admin / admin or admin / (blank)
    • Sometimes the correct login info is printed on a label on the router itself
  3. Navigate to LAN settings or DHCP settings. Look for DHCP Reservation (sometimes called Address Reservation or Static Leases).
  4. You should see a table with columns like IP Address, MAC Address, and Device Name (Alias):
    1. Enter a device name (alias) โ€“ this can be anything you like.
    2. Choose a static IP address from your LAN range. Make sure it is outside of the DHCP pool to avoid conflicts. Common examples:
      • 192.168.0.10
      • 192.168.0.11
      • 192.168.1.10
      • 192.168.1.11
    3. Enter the MAC address of your device.
  5. Save your changes โ€“ done!

Mikrotik Routers

  1. Open your Mikrotik web interface (default is 192.168.88.1, unless you changed it).
  2. Log in.
  3. Go to IP โ†’ DHCP Server โ†’ Leases.
  4. Find the device you want to make static and click it.
  5. In the Actions menu, select Make Static.
  6. Refresh the page, then edit the lease to set your desired static IP address.
  7. Save changes โ€“ done!

TP-Link

  1. Open the web interface (192.168.0.1 or 192.168.1.1).
  2. Log in (default: admin / admin).
  3. Go to DHCP โ†’ Address Reservation.
  4. Click Add New.
  5. Enter the MAC address of your device, the desired IP address, and a description (name).
  6. Save, then reboot the router if required.

TP-Link via Deco App

(works only when Deco is set to Router mode, not in Access Point mode)

  1. Open the Deco app on your phone.
  2. Go to More โ†’ Advanced โ†’ Address Reservation.
  3. Tap + Add.
  4. Select your device from the list of connected devices.
  5. Assign the desired IP address.
  6. Save โ€“ done!

ASUS

  1. Open the router page (192.168.1.1).
  2. Log in (default: admin / admin).
  3. Go to LAN โ†’ DHCP Server tab.
  4. Find Manually Assigned IP around the DHCP list.
  5. Select your device from the list or manually type in the MAC address.
  6. Enter the desired IP address.
  7. Click Add and then Apply.

Netgear

  1. Open the router page (192.168.1.1 or routerlogin.net).
  2. Log in (default: admin / password).
  3. Go to Advanced โ†’ Setup โ†’ LAN Setup.
  4. Find the section Address Reservation and click Add.
  5. Select your device from the connected devices list (or enter MAC manually).
  6. Enter the desired IP address.
  7. Save your changes.

On Windows 10/11

  1. Open Control Panel โ†’ Network and Sharing Center.
  2. Click Change adapter settings.
  3. Right-click your active connection โ†’ Properties.
  4. Select Internet Protocol Version 4 (TCP/IPv4) โ†’ Properties.
  5. Choose Use the following IP address and fill in:
    • IP address: 192.168.1.50
    • Subnet mask: 255.255.255.0
    • Default gateway: 192.168.1.1
  6. Choose Use the following DNS server addresses and set for example:
    • Preferred: 8.8.8.8
    • Alternate: 1.1.1.1
  7. Save โ€“ done!

On macOS

  1. Go to System Settings โ†’ Network.
  2. Select your active network (Wi-Fi or Ethernet).
  3. Click Details (or Advancedโ€ฆ in older macOS versions).
  4. Go to the TCP/IP tab.
  5. From the Configure IPv4 dropdown, select Manually.
  6. Fill in your details:
    • IP Address: 192.168.1.50
    • Subnet Mask: 255.255.255.0
    • Router: 192.168.1.1
  7. Go to the DNS tab and set e.g. 8.8.8.8, 1.1.1.1.
  8. Save โ€“ done!