We address the question of what are the molecular mechanisms providing discrimination between seemingly similar counterions binding to various biomolecular surfaces. In the case of protein association with Na+ and K+ ions, recent works proposed that specificity of carboxylate functional groups interacting with these mobile ions rationalizes the observed ionic discrimination. We probe in this work whether similar arguments may be used to explain higher propensity of Na+ ions to associate with DNA compared with K+ ions, which was suggested by our simulations and some experiments. By comparing our extensive molecular dynamics simulations of Na+ and K+ distributions around a 16-base-pair DNA oligomer, [(CGAGGTTTAAACCTCG)]2, with additional simulations where DNA is replaced by a "soup" of monomers (dimethylphosphate anion), we conclude that DNA specificity toward Na+/K+ is not determined by the underlying functional group specificity. Instead, the collective effect of DNA charges drives larger Na+ association. To gain additional microscopic insights into the mechanisms of specificity on ionic associations in these systems, we carried out energetic analysis of the association between Na+ and K+ with chloride and dimethylphosphate anions. The insights gained from our computational work shed light on a number of experiments on electrolyte solutions of monovalent salts and DNA.