Practice! Correct position: is with your head neutral-shoulders slightly rounded-shoulders extended. As a "trick" you may find arching your back an easier way to maintain a handstand longer.
To star off, you could try leaning against the wall. Tilt your body forward, hands on the floor and thrust you legs up. After a while, balance will come.