If we replace the hydrogen of an acid with metal, it forms a salt. e.g. HCl is an acid, if we replace hydrogen of this acid with a metal like sodium(Na), it will form NaCl. NaCl is a salt of sodium metal, which is a neutral compound. It can be prepared by neutralizing HCl with a base like NaOH.