Separation of single or mixed dyes in saline solutions can recover valuable chemicals from dye-containing wastewater. Application of ultrafiltration (UF) in this area is limited by the performance of traditional UF membranes and remains a challenge to achieve high efficacy. Herein, three uncharged polyacrylonitrile-tris(hydroxymethyl)aminomethane (PAN-Tris) UF membranes were adopted for anionic dye separation in saline solutions. These membranes were prepared via in situ modification and characterized by XPS, 1H NMR spectroscopy, contact angle, permeation, mechanical properties, etc. Congo red (CR), methyl blue (MB), and methyl orange (MO) were chosen as model dyes with different sizes and valences. The as-prepared PAN-Tris membranes possessed mean pore sizes ranging from 8.14 to 10.98 nm, but with strong negative zeta potential ranging from −12 to −43 mV at pH 7. Thus, they rejected above 98% CR (with large molecular size) and MB (with high valence), and fractionated the mixtures of CR or MB with MO (with monovalence) in water solutions. The maximum flux of a dye solution reached about 85 L⋅m−2⋅h−1 at 1 bar. Subsequently, the influences of operating pressure, dye concentration, pH value, salt type (NaCl, Na2SO4, MgCl2, or MgSO4) and salt concentration (1000, 5000, or 10000 ppm) on the dye separation property of the membranes were investigated. The results showed that dye rejection behavior depends on the molecular size and valence of dye, as well as membrane property. Thereafter, the electric double layer (EDL) model and the static permeation analysis were combined to investigate the separation mechanism through the changes of the electrostatic effects and effective pore sizes of the membranes in saline solutions. Guided by the revealed mechanism, the MB/CR mixture was successfully separated by using a NaCl solution (≥5000 ppm) for the first time. Overall, this study not only demonstrates that novel UF membranes hold promise for highly effective treatments of dye-containing wastewater, and but also provides an insightful understanding of the dye rejection mechanism that can guide the rational design of UF membranes.