Aptamers can be highly specific for their targets, which implies precise molecular recognition between aptamer and target. However, as small polymers, their structures are more subject to environmental conditions than the more constrained longer RNAs such as those that constitute the ribosome. To understand the balance between structural and environmental factors in establishing ligand specificity of aptamers, we examined the RNA aptamer (NEO1A) previously reported as specific for neomycin-B. We show that NEO1A can recognize other aminoglycosides with similar affinities as for neomycin-B and its aminoglycoside specificity is strongly influenced by ionic strength and buffer composition. NMR and 2-aminopurine (2AP) fluorescence studies of the aptamer identified a flexible pentaloop and a stable binding pocket. Consistent with a well-structured binding pocket, docking analysis results correlated with experimental measures of the binding energy for most ligands. Steady state fluorescence studies of 2AP-substituted aptamers confirmed that A16 moves to a more solvent accessible position upon ligand binding while A14 moves to a less solvent accessible position, which is most likely a base stack. Analysis of binding affinities of NEO1A sequence variants showed that the base in position 16 interacts differently with each ligand and the interaction is a function of the buffer constituents. Our results show that the pentaloop provides NEO1A with the ability to adapt to external influences on its structure, with the critical base at position 16 adjusting to incorporate each ligand into a stable pocket by hydrophobic interactions and/or hydrogen bonds depending on the ligand and the ionic environment.