Sodium chloride contains two different elements, sodium (Na) and chlorine (Cl), chemically bonded in a fixed ratio. A substance made from chemically bonded elements is a compound, so sodium chloride is a compound.
AI-written and checked against the verified answer.