Plasma electrolytic oxidation (PEO) coatings were grown on AZ31 Mg alloy in a silicate-based electrolyte containing KF using unipolar and bipolar (usual and soft-sparking) waveforms. The coatings were dual-layered consisting of MgO, MgF2 and Mg2SiO4 phases. Surface morphology of the coatings was a net-like (scaffold) containing a micro-pores network, micro-cracks and granules of oxide compounds. Deep pores were observed in the coating produced by unipolar and usual bipolar waveforms. The soft-sparking eliminated the deep pores and produced the lowest porosity in the coatings. It was found that the corrosion performance of the coatings evaluated using EIS in 3.5 wt. % NaCl solution is mostly determined by the inner layer resistance, because of its higher compactness. After 4 days of immersion, the inner layer resistances were almost the same for all coatings. However, the coatings produced by unipolar and usual bipolar waveforms showed sharp decays in inner layer resistances after 1 week and even the barrier effect of outer layer was lost for the unipolar-produced coating after 3 weeks. The low-frequency inductive loops appeared after a 3-week immersion for all coatings indicated that the substrate was under local corrosion attack. However, both coatings produced by soft-sparking waveforms provided the highest corrosion performance.