Nucleotides are held together by two types of bonds: phosphodiester bonds and hydrogen bonds. Education Portal describes phosphodiester bonds as bonds that link nucleotides into linear chains. According to Cambridge Physics, hydrogen bonds act as a bridge that connects two parallel rows of nucleotides. This connection aids in the formation of DNA's distinctive double-helix structure.
Wikipedia states that a nucleotide consists of a five-carbon sugar, a nitrogen base and one or more phosphate groups. The five-carbon sugar portion of a nucleotide contains two free hydroxyl groups that are highly reactive. Phosphate groups are also reactive and seek out a place to bond. Education Portal states that phosphodiester bonds form between a phosphate group on one nucleotide and a free hydroxyl group on a neighboring nucleotide.
The nitrogen base of each nucleotide always lines up along the same side of the chain. In DNA, a second nucleotide chain runs parallel to the first, but its orientation is flipped 180 degrees. This allows the nitrogen bases to meet in the center of the DNA structure. Wikipedia states that the hydrogen bonds that hold the two strands of nucleotides together only form between base pairs. Base pairs describe two different nitrogen bases that bond together as a rule.