In most cases when independent applications can connect to the Internet and a browser can not, this the solution.
First scan thoroughly the computer for Virus and Malware.
If clean. or after cleaning do this.
WinSock and TCP/IP Refresh.
Type Cmd in the Start Search text box.
Press Ctrl-Shift-Enter keyboard shortcut to run a Command Prompt as an Administrator. Allow elevation.
Type netsh winsock reset in the Command Prompt , and then press the Enter key.
Do the same process for refreshing the TCP/IP just replace the typed command with.
netsh interface ipv4 reset press Enter
netsh interface ipv6 reset press Enter
ipconfig /flushdns press Enter
Restart your Computer.