====== Static IP Setup ===== Assign a static IP to your server for reliable port forwarding. > //Port forwarding rules point to specific IP addresses, so a changing IP breaks the configuration.// ===== Overview ===== DHCP assigns temporary IP addresses that can change. Port forwarding rules point to specific IP addresses, so a changing IP breaks the forwarding. Setting a static IP ensures your server always has the same address. ===== Why Static IP is Needed ===== * Port forwarding rules point to specific IP addresses * DHCP can change IP addresses periodically * Changing IP breaks port forwarding configuration * Static IP ensures consistent access ===== Option A: DHCP Reservation (Preferred) ===== DHCP reservation tells your router to always assign the same IP to your server based on its MAC address. **Steps:** 1. Log into router admin panel 2. Find DHCP settings 3. Look for "DHCP reservation" or "static lease" 4. Find your server by MAC address 5. Assign it a fixed IP (e.g., 192.168.1.50) 6. Save and apply **Advantages:** * Managed centrally from router * Easy to change if needed * No device configuration required ===== Option B: Static IP on Device ===== Configure the static IP directly on your server. **Steps:** 1. Find your network settings 2. Change from automatic to manual 3. Enter IP address (e.g., 192.168.1.50) 4. Enter subnet mask (usually 255.255.255.0) 5. Enter gateway (router IP) 6. Enter DNS (router IP or 8.8.8.8) **Advantages:** * Works even if router changes * No router configuration needed * Device has consistent IP regardless of network ===== Verify Static IP ===== 1. Restart your server 2. Check IP address hasn't changed 3. Confirm in router's DHCP client list 4. Test connectivity to router ===== Troubleshooting ===== **IP conflict:** * Another device may be using the same IP * Choose a different IP address * Check router's DHCP client list for conflicts **Can't access network:** * Verify subnet mask and gateway are correct * Check cable connection * Try different IP address ===== References ===== * [[https://www.expressvpn.com/blog/how-to-open-ports-on-router/|How to open ports on your router]] * [[https://www.samnet.dev/learn/networking/port-forwarding-guide/|Port Forwarding Explained: How to Open Ports on Your Router]] ===== See Also ===== * [[hosting:networking:start|Networking Overview]] * [[hosting:networking:port_forwarding|Port Forwarding]] Last updated: 2026-06-19 * [[hosting:start|Return to hosting]]