Device sending local traffic directly and remote traffic through its default gateway

A default gateway is the next-hop router a device uses when no more specific route matches a destination. Find yours in the active connection’s network settings or routing table. If it is blank or unavailable, check the connection and address configuration first.

The routing distinction follows RFC 1122’s gateway-selection rules. Record your connection, device address and gateway. Then compare local reachability, internet access and name resolution to locate the fault before changing settings.


Key Facts

  • A default gateway is the next-hop router used when no more specific route matches.
  • The IPv4 default destination is 0.0.0.0/0.
  • The IPv4 prefix /24 corresponds to the subnet mask 255.255.255.0.
  • DHCP can supply router addresses to clients.
  • A router can serve as both the default gateway and the DNS server.

What a default gateway does

A default gateway forwards traffic toward destinations that have no more specific matching route. Devices on the same local network usually communicate directly.

Consider this IPv4 network: your computer is 192.168.1.20/24, another device is 192.168.1.30, and the gateway is 192.168.1.1. With the ordinary connected route, traffic to 192.168.1.30 goes directly across the local network. Traffic to an unmatched remote destination goes through 192.168.1.1. The /24 prefix corresponds to the subnet mask 255.255.255.0. See RFC 1122’s local/remote decision and our introduction to IPv4 and IPv6.

In a routing table, 0.0.0.0/0 is the IPv4 default destination: it matches any IPv4 address. Read the router’s address in the next-hop field. A more specific matching route takes precedence and can use a different next hop. RFC 1812 explains longest-match route selection.


Find your default gateway on your device

Read the gateway for the connection carrying your traffic. When Wi-Fi, Ethernet or VPN connections are active together, inspect the selected route to the destination you are troubleshooting.

Windows

Open Command Prompt and run:

ipconfig

Find Default Gateway under the connected Wi-Fi or Ethernet adapter. IPv4 Address is your device’s address. Microsoft documents these fields; our ipconfig guide explains the wider output.

If several connections are active, find the route for a particular destination in PowerShell:

Find-NetRoute -RemoteIPAddress 1.1.1.1

Find-NetRoute returns a local-address object and a route object. Read InterfaceIndex and NextHop from the route object; IPAddress in the other object is your device’s source address. DestinationPrefix shows the selected route’s destination range, which may be more specific than the default route. Microsoft documents these output objects.

macOS

Open System Settings > Network > your connection > Details > TCP/IP. Read Router, as described in Apple’s TCP/IP settings documentation.

For a routing-table lookup in Terminal:

route -n get default

Read the gateway and interface fields together. Apple’s route manual source documents numeric output, route lookup and the default destination. Applications using interface-scoped routes can take different paths.

Linux

Display the IPv4 routes in the main routing table:

ip route

In a default-route entry, default identifies the destination, via the next-hop address, and dev the outgoing interface. Multiple defaults can coexist; lower metrics are preferred among otherwise comparable routes.

To inspect the selected route toward one destination:

ip route get 1.1.1.1

This looks up a route without testing connectivity. VPN or policy routing can use other tables. A valid default route can name an interface without a via address. The ip-route manual documents these fields and lookup behavior.

iPhone and Android

On iPhone, open Settings > Wi-Fi, tap the information icon beside the connected network, and read Router. Linksys illustrates these iPhone steps.

On Samsung Galaxy devices that offer Manage router, open Settings > Connections > Wi-Fi, then the connected network’s gear icon > Manage router. Linksys documents this management shortcut. A browser redirect can lead to a management address that differs from your configured gateway. Menus vary by model and software version; consult your model’s documentation if the option is absent.

One command per system


Default gateway is not available: find the cause

Compare another device on the same network to separate device faults from shared connection problems.

Symptom Check Meaning Fix
Blank gateway Active adapter and routes Missing configuration or intentional local-only access Reconnect; restore intended settings.
Gateway unreachable Another device and local service Device or LAN trouble Check connection and configuration.
Gateway responds, external access fails Compare another device; test external IP connectivity and DNS separately; inspect router WAN status Failures across devices point toward shared forwarding, WAN or ISP trouble; a single-device failure points toward that device If multiple devices fail and WAN status shows a fault, check the router/modem connection and ISP. For one-device failures, inspect its configuration and software. For name-resolution failures, follow the DNS branch.
IP connectivity works, names fail DNS lookup DNS resolution needs investigation Check DNS configuration and reachability.
Internet works, management page fails Documented management method Separate management issue Check address, scheme and port.

These branches combine checks from Microsoft’s connection troubleshooting guidance.

On Windows, replace the example address with your recorded gateway:

ping /n 4 192.168.1.1

Replies confirm ICMP reachability. ICMP filtering can cause timeouts while other traffic works, so compare another device and an available local service. Routers can suppress echo replies; see our ping guide.

Next, test an external IPv4 destination:

ping /n 4 1.1.1.1

Replies confirm ICMP reachability to that destination. Test the affected application next to check its connection. Microsoft documents ping.

For DNS, replace the example domain with the affected hostname:

nslookup dataimpulse.com

Inspect the queried server and answer. A returned address shows this query succeeded. A timeout means no timely response; Nonexistent domain means the server reported that the queried name does not exist. See Microsoft’s error definitions and our nslookup guide. If an external IP responds but lookups time out, investigate the configured resolver and its network path.

Follow router management documentation before changing port forwarding.


Gateway, router, subnet mask, DNS and default route

Your device’s IP address identifies its interface; the gateway address identifies a next hop.

Term Role
Default gateway Next-hop router for the default path.
Router System that forwards packets between networks; routing can run in software.
Subnet mask Identifies the network portion of an IPv4 address.
DNS server Resolves names, including hostname-to-address queries.
Default route Fallback routing entry; its next hop may be called the gateway of last resort.

RFC 1812 defines router and routing behavior. A gateway and DNS server can share an address because one device performs both roles; RFC 5625 describes DNS proxies in broadband gateways.

Read your configured gateway rather than calculating it from your device’s IP address. Addresses such as 192.168.0.1, 192.168.1.1 and 10.0.0.1 are common examples; your network determines which address to use. DHCP can deliver router addresses through its router option.

For Cisco equipment, ip default-gateway applies when IP routing is disabled. A routing-enabled device uses a default route instead.


Choosing settings and verifying recovery

Use the gateway assigned for your network, including on a gaming PC, PS4 or PS5.

DHCP distributes settings, including router addresses. Static configuration requires a coordinated device address, subnet mask, gateway and DNS settings. Review static versus dynamic IP before changing your configuration.

Windows recovery order

Reconnect first. Run ipconfig /all and inspect DHCP Enabled, IPv4 Address, Default Gateway and DNS Servers under the affected adapter. If it should use DHCP, open Command Prompt as administrator and run:

ipconfig /renew "Wi-Fi"

Replace "Wi-Fi" with the exact adapter name. Recheck its configuration afterward. For deliberate static settings, correct the configured values manually. Microsoft documents adapter-specific renewal.

If the fault remains device-specific, investigate the adapter driver. Leave network reset until last: it removes installed adapters and their settings, and networking software may need reconfiguration. Follow Microsoft’s recovery guidance.

Confirm recovery

  • Recheck the active connection and selected route.
  • Confirm local connectivity using an available local service.
  • Check external connectivity and DNS resolution separately.
  • Retry the application that originally failed.

Without a default route, your device can still reach connected networks and destinations covered by specific routes. Other destinations need a matching route. See the routing behavior in the ip-route manual.


Frequently Asked Questions

Can I find my default gateway from my IP address?

Read the gateway setting or routing table. Your IP address and subnet mask describe your local network; the configured route identifies its gateway.

Is 0.0.0.0 my router address?

The destination 0.0.0.0/0 identifies the IPv4 default route. Read your router’s address in the gateway or next-hop field.

Why is the default gateway blank?

Check the connected adapter first. A blank value can reflect incomplete address configuration or intentional local-only access. Restore the settings assigned for your network.

Does an unsuccessful gateway ping mean the router is broken?

A router can ignore echo requests while still forwarding traffic. Compare another device and test a local service to locate the fault.

Why does the internet work when the gateway page will not open?

Packet forwarding and router management are separate functions. Check your router’s documented management address, scheme and port.

Should my gateway and DNS server have different addresses?

Both can share an address when the router also handles DNS queries. Test forwarding and name resolution separately.


Keep a Record of Your Working Connection

Once access returns, record the active adapter, device address, subnet mask, gateway and DNS settings. If the issue returns, compare those values and note whether one application, one device or the whole network is affected.

Last updated: November 19, 2026.