In my experience lying still doesn't really work, because it's a deliberate practice with a goal and your brain starts analyzing that as well. You know the inner voice that says: I am still not calming down, I am still awake.
I once read that sleep therapists sometimes give people with bad sleeping problems the opposite advice: keep your eyes slightly open and try to stay awake. Not in the sense that you should put on loud music, put lucifers between your eyelids, etc. But just lie down and don't try to fall asleep. It often works, because people let go of the goal to calm down and get asleep (which makes it hard to do exactly that), once you let go, your body does what it wants to do, calm down and sleep.
A similar approach works very well for me: just stop caring. Ensure that you are on a regular schedule for going to bed and waking up (so that you biological clock doesn't get confused), don't drink alcohol (bad sleep quality), don't do anything exciting the hours before going to bed (heated discussions on HN), and write down stuff that bothers you before going to bed. Let your body do the rest. If you are awake for some more time, then just interpret it as: my body isn't tired yet, I am just going to enjoy the cosiness of my bed.
Disclaimer: I am not a doctor/therapist.