The adsorption of partially hydrolyzed polyacrylamide (HPAM) on quartz plays a key role in solid-liquid separation processes that seek to recover water for processing. In this work, computational molecular dynamics is used to study the water-quartz interface in the presence of HPAM under conditions of high salt and wide pH range. The salts used are mostly those of seawater. Small water-structure maker cations are preferentially adsorbed onto the polymer rather than onto the quartz surfaces. In freshwater, the adsorption of HPAM on quartz is reduced to very few contacts, however in saltwater the adsorption contacts of HPAM increase although decrease with surface charge, mainly due to electrostatic repulsion. In the presence of monovalent cations and for any surface charge on the quartz, above the isoelectric point, the adsorption contacts of HPAM decreases as the cation size increases, which is expected considering that smaller cations are more effective in neutralizing both quartz and HPAM. The results show that the adsorption of HPAM occurs exclusively via salt bridges. One way of describing the conformation of an HPAM chain adsorbed onto quartz is to reduce it to the skeleton of carbon atoms of the polymer chain and then determine the fraction of these atoms in loops, trains, and tails. In general, the adsorption contacts of HPAM are few, the carbon fractions in trains and loops are tiny, and therefore most of the carbon atoms in HPAM remain in long tails ready to get entangled with other tails thus favoring the flocculation process. The results are expected to contribute to sustainable water management through the right choice of flocculant based on molecular aspects.