Catalyzes the last step of the phosphorylated serine biosynthetic pathway, i.e. dephosphorylation of O-phospho-L-serine to form L-serine. To a lesser extent, is also able to dephosphorylate phosphothreonine, phosphoethanolamine, and histidinol phosphate in vitro. H2O + O-phospho-L-serine = L-serine + phosphate H2O + O-phospho-D-serine = D-serine + phosphate The stereochemistry of phosphoserine and phosphothreonine is not specified in the article. kcat is 6.9 sec(-1) with phosphoserine as substrate. kcat is 9.5 sec(-1) with phosphothreonine as substrate. kcat is 7.9 sec(-1) with phosphoethanolamine as substrate. kcat is 7.1 sec(-1) with histidinol phosphate as substrate. Amino-acid biosynthesis; L-serine biosynthesis; L-serine from 3-phospho-D-glycerate: step 3/3. Cells lacking this gene cannot grow in minimal medium, in contrast to wild type. ysaA, serA, and serC deletion mutants have virtually identical profiles when observed across all the conditions studied, likely placing YsaA in the serine biosynthesis pathway. The defect is complemented by glycine, or a combination of serine and other amino acids such as glutamine or glutamate. The inability of serine alone to rescue the growth defect of the deletion mutant is due to serine toxicity. ysaA complements E.coli serB and vice versa. Belongs to the HAD-like hydrolase superfamily.