Here's why:
* Potassium is a metal and forms a cation (K+).
* Chlorine is a nonmetal and forms an anion (Cl-).
* When naming ionic compounds, the metal cation is named first, followed by the nonmetal anion with its suffix changed to "-ide".
Therefore, the compound containing potassium and chlorine is called potassium chloride.