Coconut oil rubbed into the scalp and hair, left for several hours, then washed out with a mild soap, such as castile soap, will get rid of dandruff within a couple of days. I spent much of my childhood growing up in Asian countries and this is a much used and effective treatment for dandruff and other fungal infections.
That is because coconut oil contains caprylic acid, which kills fungi.