The number equal to an atom’s proton number and its electron number when the atom is neutral is the atomic number. It is represented by the symbol Z and identifies which chemical element the atom is.
Every atom of carbon has six protons, so carbon’s atomic number is 6. A neutral carbon atom also has six electrons because the positive charges of the protons exactly balance the negative charges of the electrons. Changing the number of protons changes the element itself.
The atomic number is not the same as the mass number. Mass number counts protons plus neutrons, so isotopes of one element have the same atomic number but different mass numbers. For example, carbon-12 and carbon-14 both have six protons, but they contain different numbers of neutrons.
Ions demonstrate why the neutrality condition matters: a chloride ion has 17 protons but 18 electrons. Its atomic number remains 17, while its electrical charge changes because the proton and electron counts no longer match.