The valency of an ion is the number of electrons that it can lose or gain in order to become neutral. In the case of the sulphate ion, it can gain two electrons to become neutral, so it has a valency of -2.
The valency of an ion is important because it determines how it will react with other ions. For example, the sulphate ion will react with positively charged ions, such as sodium ions, to form salts.