You can't. It depends on what is driving your brain to not be avle to turn off.
Ocd patients frequently have trouble with sleep because they are constantly making lists of things that need to be done or going over the day that has ended. Bipolar patients can't stop their brains because of the racing thoughts. If there is no mental health problem, good sleep hygiene