In the test for sulfate ions (SO42−\text{SO}_4^{2-}SO42−) in aqueous solution, dilute hydrochloric acid is added before the addition of barium chloride solution.
Why is hydrochloric acid added?
It increases the concentration of chloride ions.
It reacts with and removes other ions, such as carbonate, that would otherwise form a precipitate with barium ions.
It prevents barium sulfate from dissolving in water.
It provides the acidic conditions required for the precipitation of barium sulfate.