Detailed information can be found in the post How can I set / change DNS using the command-prompt at windows 8, which I summarize below :
First, find the network interface name by entering in the Command Prompt :
netsh interface show interface
This may show something like :
Admin State State Type Interface Name ------------------------------------------------------------------------- Enabled Connected Dedicated Local Area Connection
To change the DNS server to Google, enter :
netsh interface ipv4 add dnsserver "Local Area Connection" 8.8.8.8 index=1
This will set the Google DNS server as the first DNS server in the list of DNS servers for the interface.
To reset the interface back to DHCP enter :
netsh interface ipv4 set address name="Local Area Connection" dhcp
For more information see :