* Aluminum (Al) is a metal, and it tends to lose three electrons to achieve a stable electron configuration. This creates a positively charged aluminum ion (Al³⁺).
* Fluorine (F) is a nonmetal, and it tends to gain one electron to achieve a stable electron configuration. This creates a negatively charged fluoride ion (F⁻).
The strong electrostatic attraction between the positively charged aluminum ion and the negatively charged fluoride ions results in the formation of an ionic compound, aluminum fluoride (AlF₃).