How do you get herobrine in minecraft?

you cannot, he is simply a myth.
You have to download a mod that contains him. This can only be done on the PC version, but will come with full instructions on how to do it.