How to login to Docker hub from the command line

TL;DR

you have to enter your Docker ID, and not your email address ?

!Tl;DR

In this quick tip, I’ll show you (and help me remember forever and always ?) how to login to Docker hub from the command line.

I won’t go into details of why and how Docker is great and why all devs should use it, I’ll leave that for some other post…

I’m using the Docker for Mac desktop app.

You can download a version for your operating system here.

Via the Docker for Mac app I could login without a problem with my email and password.

However, if I typed docker login from the command line, it would constantly keep telling me I provided wrong credentials. On this Github issue I found the solution:

you have to enter your Docker ID, and not your email address ?

Written by Nikola Brežnjak