curl http://example.com
returns HTTP 401 error,
when I open http://example.com in the browser it shows :

how to enter the username and password through curl
Note:
I have tried this one based on one of the answers and I get the same message :
curl --user myuser:123456 http://example.com
401 Unauthorized
The Solution
I’ve just added “–ntlm” and it works !
curl --user myuser:123456 http://example.com --ntlm
I’ll choose the nearest answer…
Have you tried :