The molecular formula for water is H20. Two hydrogen atoms and one oxygen atom form a covalent bond. Hydrogen is slightly positively charged and is attracted to oxygen which is slightly negatively charged. The atoms share outer shell electrons to obtain a full outer shell, making the molecule stable.