Atom Calculator

Protons + neutrons, e.g. 23 for sodium-23.
0 for a neutral atom, +2 for Ca²⁺, −2 for S²⁻.
Chemistry Updated 5 Nov 2026

Counts the protons, neutrons and electrons in an atom or ion, or works backwards from those particles to the atomic number Z, mass number A and charge. Pick the element from the list of all 118 (or enter the protons), give the mass number and the charge, and the calculator returns p = Z, n = A − Z and e = Z − charge, plus the isotope symbol such as ²³Na or ³²S²⁻. A third mode accepts any mix of known values, such as an ion with mass number 195 and 74 electrons, and checks that the numbers agree with each other.

  • All counts and the charge are whole numbers; the charge is in units of the elementary charge.
  • Any mass number A ≥ Z is accepted; the calculator does not check whether that isotope has been observed or is stable.

Formula

p = Z; n = A − Z; e = Z − charge ⇔ Z = p; A = p + n; charge = p − e
  • The atomic number Z is the number of protons and fixes the element: every atom with 11 protons is sodium, whatever its neutrons or electrons.
  • The mass number A counts nucleons (protons + neutrons). Electrons are left out because each has only about 1/1,800 of the mass of a proton.
  • Charge is in units of the elementary charge: a cation has lost electrons (positive charge), an anion has gained them (negative charge).
  • In the mixed mode, Z can come from the element, the protons, A − n or e + charge; if two of these disagree the calculator says which ones conflict.
  • The checks are A ≥ Z (no negative neutrons), electrons = Z − charge ≥ 0 and 1 ≤ Z ≤ 118. Whether a nuclide such as sodium-40 actually exists is not checked.

Neutral sodium-23 atom

Inputs
  • What do you know?: numbers
  • Element (atomic number Z): Na
  • Mass number (A): 23
  • Charge: 0
  • Protons (p): 16
  • Neutrons (n): 16
  • Electrons (e): 18
  • Element (atomic number Z): Pt
  • Protons (p):
  • Neutrons (n):
  • Electrons (e): 74
  • Mass number (A): 195
  • Charge:

Sodium has atomic number Z = 11, so it has 11 protons. With mass number A = 23 it has 23 − 11 = 12 neutrons, and with charge 0 it has 11 − 0 = 11 electrons. The symbol is ²³Na. Switching to the particle mode with 16 protons, 16 neutrons and 18 electrons gives Z = 16 (sulfur), A = 16 + 16 = 32 and charge 16 − 18 = −2, the sulfide ion ³²S²⁻.

Sources & references

  • Chemistry 2e, Section 2.3: Atomic Structure and Symbolism
    OpenStax, Rice University · Retrieved 5 Nov 2026

    Definitions Z = protons, A = protons + neutrons, A − Z = neutrons, charge = protons − electrons; Example 2.3 (¹²⁷I⁻: 53 p, 74 n, 54 e) and its check (A 195, 74 e → 78 p, 117 n, 4+).

  • Periodic Table of Elements
    International Union of Pure and Applied Chemistry (IUPAC) · Retrieved 5 Nov 2026

    Names, symbols and atomic numbers of elements 1–118 used in the element list.

Frequently asked questions

How do I find the number of neutrons?
Subtract the atomic number from the mass number: n = A − Z. Iodine-127 has Z = 53, so it has 127 − 53 = 74 neutrons. The charge does not affect the neutron count.
How many electrons does an ion have?
Subtract the charge from the atomic number: e = Z − charge. The iodide ion I⁻ has 53 − (−1) = 54 electrons, while Ca²⁺ has 20 − 2 = 18 electrons.
How do I find the charge from protons and electrons?
Charge = protons − electrons. A platinum ion with 78 protons and 74 electrons has a charge of 78 − 74 = +4, written Pt⁴⁺. More protons than electrons gives a cation; more electrons gives an anion.
Is the mass number the same as the atomic mass?
No. The mass number is a whole-number count of protons and neutrons in one nucleus. The atomic mass in the periodic table, such as 22.990 for sodium, is an average over the natural isotopes measured in daltons, so it is usually not a whole number. For a single atom the mass in daltons is close to, but not exactly, its mass number.
What is the mass number of helium with 2 neutrons?
Helium always has 2 protons (Z = 2), so A = 2 + 2 = 4, the common isotope helium-4.

Related calculators