Electron Configuration of Elements 1–118: Online Generator
Electron Configuration of Elements 1–118: Online Generator and How to Write It
Type a symbol, name or atomic number (or an ion such as Fe3+ or Cl-) to see the full electron configuration, noble-gas notation, electrons per shell, valence electrons, group and period, and the orbital diagram.
What is an electron configuration?
An electron configuration describes how an atom’s electrons are arranged in shells and subshells. It is written with the shell number (n), the subshell letter (s, p, d, f) and the number of electrons as a superscript. Oxygen, with 8 electrons, is 1s2 2s2 2p4.
The configuration tells you the valence electrons, the element’s position in the periodic table and the ions it is likely to form, which is why it underpins chemical bonding and periodic trends.
Shells and subshells
Electrons occupy the K, L, M, N... shells (n = 1, 2, 3, 4...). A shell holds at most 2n² electrons. Each shell is split into subshells, and each orbital holds at most 2 electrons.
| Shell | n | Subshells | Maximum (2n²) |
|---|---|---|---|
| K | 1 | 1s | 2 |
| L | 2 | 2s 2p | 8 |
| M | 3 | 3s 3p 3d | 18 |
| N | 4 | 4s 4p 4d 4f | 32 |
| Subshell | Orbitals | Maximum electrons |
|---|---|---|
| s | 1 | 2 |
| p | 3 | 6 |
| d | 5 | 10 |
| f | 7 | 14 |
The three filling rules
1. The Aufbau principle
Electrons fill subshells from the lowest energy upward, following the n + l rule; when n + l is equal, the subshell with the smaller n fills first:
1s → 2s → 2p → 3s → 3p → 4s → 3d → 4p → 5s → 4d → 5p → 6s → 4f → 5d → 6p → 7s → 5f → 6d → 7p
The diagonal diagram is an easy way to remember it: write the subshells of each shell in rows and draw diagonal arrows from top right to bottom left. That is why 4s fills before 3d.
2. The Pauli exclusion principle
No two electrons in an atom can share all four quantum numbers, so one orbital holds at most two electrons with opposite spins (↑↓).
3. Hund’s rule
Within a set of equal-energy orbitals, electrons occupy empty orbitals singly with parallel spins before pairing up. Nitrogen (2p3) has three unpaired electrons: ↑ ↑ ↑, while oxygen (2p4) has one paired orbital: ↑↓ ↑ ↑.
Configuration by shell (Bohr model)
School textbooks often write electrons per shell, for example sodium 2 8 1 and chlorine 2 8 7. For main-group elements, each shell holds at most 2n² electrons and the outer shell at most 8, so potassium is 2 8 8 1 rather than 2 8 9.
For transition metals, derive the shell counts from the subshell configuration. Take iron, [Ar] 4s2 3d6: the M shell holds 3s2 3p6 3d6 = 14 electrons and the N shell holds 4s2, giving 2 8 14 2. The generator above shows the shell counts for every element.
Noble-gas notation
Long configurations are shortened with the previous noble gas in square brackets: sodium is [Ne] 3s1 and iron is [Ar] 4s2 3d6. The cores are He (2), Ne (10), Ar (18), Kr (36), Xe (54) and Rn (86).
Exceptions to the Aufbau principle
Some elements break the filling order. The best known are chromium and copper: a half-filled (d5) or filled (d10) d subshell is more stable, so one 4s electron moves into 3d. Among the lanthanides and actinides, f and d subshells are so close in energy that other exceptions appear. The full list, based on PubChem data:
| Element | Aufbau prediction | Actual |
|---|---|---|
| Cr · Chromium | [Ar] 4s2 3d4 | [Ar] 4s1 3d5 |
| Cu · Copper | [Ar] 4s2 3d9 | [Ar] 4s1 3d10 |
| Nb · Niobium | [Kr] 5s2 4d3 | [Kr] 5s1 4d4 |
| Mo · Molybdenum | [Kr] 5s2 4d4 | [Kr] 5s1 4d5 |
| Ru · Ruthenium | [Kr] 5s2 4d6 | [Kr] 5s1 4d7 |
| Rh · Rhodium | [Kr] 5s2 4d7 | [Kr] 5s1 4d8 |
| Pd · Palladium | [Kr] 5s2 4d8 | [Kr] 4d10 |
| Ag · Silver | [Kr] 5s2 4d9 | [Kr] 5s1 4d10 |
| La · Lanthanum | [Xe] 6s2 4f1 | [Xe] 6s2 5d1 |
| Ce · Cerium | [Xe] 6s2 4f2 | [Xe] 6s2 4f1 5d1 |
| Gd · Gadolinium | [Xe] 6s2 4f8 | [Xe] 6s2 4f7 5d1 |
| Pt · Platinum | [Xe] 6s2 4f14 5d8 | [Xe] 6s1 4f14 5d9 |
| Au · Gold | [Xe] 6s2 4f14 5d9 | [Xe] 6s1 4f14 5d10 |
| Ac · Actinium | [Rn] 7s2 5f1 | [Rn] 7s2 6d1 |
| Th · Thorium | [Rn] 7s2 5f2 | [Rn] 7s2 6d2 |
| Pa · Protactinium | [Rn] 7s2 5f3 | [Rn] 7s2 5f2 6d1 |
| U · Uranium | [Rn] 7s2 5f4 | [Rn] 7s2 5f3 6d1 |
| Np · Neptunium | [Rn] 7s2 5f5 | [Rn] 7s2 5f4 6d1 |
| Cm · Curium | [Rn] 7s2 5f8 | [Rn] 7s2 5f7 6d1 |
| Lr · Lawrencium | [Rn] 7s2 5f14 6d1 | [Rn] 7s2 5f14 7p1 |
Electron configuration of ions
Cations form when an atom loses electrons. Electrons are removed from the outermost shell (largest n) first, not from the subshell filled last. So Fe2+ is [Ar] 3d6 and Fe3+ is [Ar] 3d5: both 4s electrons go first.
Anions form when an atom gains electrons, which fill the next subshell. Cl (2 8 7) becomes Cl− [Ne] 3s2 3p6 = [Ar], like argon. Type Fe3+ or O2- in the generator to try it.
Finding valence electrons, group and period
- Period = the highest occupied shell number.
- Main groups: valence electrons = ns + np. Sodium [Ne] 3s1 has 1, so it is in group 1, period 3.
- Transition metals: valence electrons = ns + (n−1)d. Iron 4s2 3d6 has 8, so it is in group 8, period 4.
- Block = the last subshell being filled: s, p, d or f.
Worked examples
Example 1: a main-group element
Give the electron configuration, valence electrons, group and period of chlorine (Z = 17).
- Place 17 electrons in Aufbau order: 1s2 2s2 2p6 3s2 3p5.
- By shell: 2 8 7. The outer shell (n = 3) holds 3s2 3p5 = 7 electrons.
Answer: 7 valence electrons, group 17 (halogens), period 3.
Example 2: a transition metal
Give the electron configuration and position of iron (Z = 26).
- 1s2 2s2 2p6 3s2 3p6 4s2 3d6, or [Ar] 4s2 3d6.
- Valence electrons = 4s2 + 3d6 = 8; the highest shell is n = 4.
Answer: group 8, period 4, d-block.
Example 3: an exception
Why is chromium (Z = 24) not [Ar] 4s2 3d4?
- The Aufbau order predicts [Ar] 4s2 3d4.
- A half-filled 3d5 subshell is more stable, so one 4s electron moves into 3d.
Answer: [Ar] 4s1 3d5, with 6 unpaired electrons.
Example 4: an ion
Write the configuration of Cu2+ (copper, Z = 29).
- Copper atom: [Ar] 4s1 3d10 (an exception).
- Remove 2 electrons: one from 4s, then one from 3d.
Answer: Cu2+ = [Ar] 3d9.
Electron configurations of elements 1–36
| Z | Element | Configuration | Per shell | Valence |
|---|---|---|---|---|
| 1 | H · Hydrogen | 1s1 | 1 | 1 |
| 2 | He · Helium | 1s2 | 2 | 2 |
| 3 | Li · Lithium | [He] 2s1 | 2 1 | 1 |
| 4 | Be · Beryllium | [He] 2s2 | 2 2 | 2 |
| 5 | B · Boron | [He] 2s2 2p1 | 2 3 | 3 |
| 6 | C · Carbon | [He] 2s2 2p2 | 2 4 | 4 |
| 7 | N · Nitrogen | [He] 2s2 2p3 | 2 5 | 5 |
| 8 | O · Oxygen | [He] 2s2 2p4 | 2 6 | 6 |
| 9 | F · Fluorine | [He] 2s2 2p5 | 2 7 | 7 |
| 10 | Ne · Neon | [He] 2s2 2p6 | 2 8 | 8 |
| 11 | Na · Sodium | [Ne] 3s1 | 2 8 1 | 1 |
| 12 | Mg · Magnesium | [Ne] 3s2 | 2 8 2 | 2 |
| 13 | Al · Aluminium | [Ne] 3s2 3p1 | 2 8 3 | 3 |
| 14 | Si · Silicon | [Ne] 3s2 3p2 | 2 8 4 | 4 |
| 15 | P · Phosphorus | [Ne] 3s2 3p3 | 2 8 5 | 5 |
| 16 | S · Sulfur | [Ne] 3s2 3p4 | 2 8 6 | 6 |
| 17 | Cl · Chlorine | [Ne] 3s2 3p5 | 2 8 7 | 7 |
| 18 | Ar · Argon | [Ne] 3s2 3p6 | 2 8 8 | 8 |
| 19 | K · Potassium | [Ar] 4s1 | 2 8 8 1 | 1 |
| 20 | Ca · Calcium | [Ar] 4s2 | 2 8 8 2 | 2 |
| 21 | Sc · Scandium | [Ar] 4s2 3d1 | 2 8 9 2 | 3 |
| 22 | Ti · Titanium | [Ar] 4s2 3d2 | 2 8 10 2 | 4 |
| 23 | V · Vanadium | [Ar] 4s2 3d3 | 2 8 11 2 | 5 |
| 24 | Cr · Chromium | [Ar] 4s1 3d5 | 2 8 13 1 | 6 |
| 25 | Mn · Manganese | [Ar] 4s2 3d5 | 2 8 13 2 | 7 |
| 26 | Fe · Iron | [Ar] 4s2 3d6 | 2 8 14 2 | 8 |
| 27 | Co · Cobalt | [Ar] 4s2 3d7 | 2 8 15 2 | 9 |
| 28 | Ni · Nickel | [Ar] 4s2 3d8 | 2 8 16 2 | 10 |
| 29 | Cu · Copper | [Ar] 4s1 3d10 | 2 8 18 1 | 11 |
| 30 | Zn · Zinc | [Ar] 4s2 3d10 | 2 8 18 2 | 12 |
| 31 | Ga · Gallium | [Ar] 4s2 3d10 4p1 | 2 8 18 3 | 3 |
| 32 | Ge · Germanium | [Ar] 4s2 3d10 4p2 | 2 8 18 4 | 4 |
| 33 | As · Arsenic | [Ar] 4s2 3d10 4p3 | 2 8 18 5 | 5 |
| 34 | Se · Selenium | [Ar] 4s2 3d10 4p4 | 2 8 18 6 | 6 |
| 35 | Br · Bromine | [Ar] 4s2 3d10 4p5 | 2 8 18 7 | 7 |
| 36 | Kr · Krypton | [Ar] 4s2 3d10 4p6 | 2 8 18 8 | 8 |
For elements 37–118 use the generator above, the interactive periodic table or each element’s page.
Frequently asked questions
What is an electron configuration?
The arrangement of an atom’s electrons in shells and subshells, for example O = 1s2 2s2 2p4. It determines valence electrons and chemical behaviour.
What is the order of filling?
By the Aufbau principle: 1s → 2s → 2p → 3s → 3p → 4s → 3d → 4p → 5s → 4d → 5p → 6s → 4f → 5d → 6p → 7s → 5f → 6d → 7p.
Why does 4s fill before 3d?
Because 4s has a lower n + l value (4 + 0 = 4) than 3d (3 + 2 = 5). When ions form, however, 4s electrons are removed first.
Which elements are exceptions?
In period 4: Cr and Cu. In period 5: Nb, Mo, Ru, Rh, Pd and Ag. In period 6: Pt and Au, plus several lanthanides and actinides. See the table above.
How do I find the group from the configuration?
Count the valence electrons: ns + np for main groups, ns + (n−1)d for transition metals. The period is the highest shell number.
Prepare solutions with analytical-grade reagents
AMI Scientific is one of the official TCI distributors in Indonesia. Reagents with lot CoA & SDS, formal quotations and tax invoices for universities and laboratories.
Other formulas & calculators: molarity, mole, molality, normality, dilution, titration, pH, buffer, molar mass, ppm, mole fraction, mass percent, periodic table, chemical MSDS.