The proper way to wash a brush is first with solvent if it's an oil-based paint or varnish, then with soap or shampoo and water.
It is hair after all.
No one actually does this. In practice people wrap the brush in a plastic bag and pretend they'll clean it tomorrow. Some time later they throw it away.
Here's a better method. Just leave the brush in the paint can. It'll stay good as long as the paint does.
This is what commercial painters do with their brushes, rollers, etc.