How to assign IP address using command line
How to assign IP address using command line
Learn how to assign an IP address using simple command-line steps on Windows.
Check Network Status >
netsh interface ipv4 show config
This shows your current network interfaces and settings.
Set IP Address
Enable DHCP:
netsh interface ipv4 set address name="INTERFACE NAME" source=dhcp
Set Static IP:
netsh interface ipv4 set address name="INTERFACE NAME" static 192.168.0.13 255.255.255.0 192.168.0.1
Set DNS:
netsh interface ipv4 set dns name="INTERFACE NAME" static 8.8.4.4
Verify:
ipconfig
⚠️ Disclaimer
Apply solutions at your own risk. Always consult a professional — we are not responsible for any system issues that may occur.