Not sure which lesson to do first? Find your level and get a plan →

Chemistry · Structure of Matter · Grade 9-12

Octet Rule

A chemical bonding principle stating that atoms tend to gain, lose, or share electrons in order to achieve a stable configuration of 8 electrons in their outermost (valence) shell.


Quick Answer

A chemical bonding principle stating that atoms tend to gain, lose, or share electrons in order to achieve a stable configuration of 8 electrons in their outermost (valence) shell. It is why sodium forms Na+, chlorine forms Cl−, and oxygen makes two bonds in water: each move leaves the atom with the outer arrangement of a noble gas. Use it to predict ion charges, the number of bonds an atom forms, and formulas such as NH3 and MgO. Hydrogen is satisfied with 2, and some molecules break the rule.

Why This Matters

The octet rule turns valence electrons into predictions. With it you can say that nitrogen bonds to three hydrogens, that calcium and fluorine make CaF2, and how to finish a Lewis structure. Knowing its limits matters too: boron in BF3 has only 6 electrons and sulfur in SF6 has 12, so a structure that breaks the rule is not automatically wrong.

Intuitive Explanation

Look at the noble gases: neon has 8 electrons in its outer shell, argon has 8, and both almost never react. The elements next to them do react, and in ways that land them on the same count. Sodium (2, 8, 1) loses its single outer electron and is left with neon's 2, 8. Chlorine (2, 8, 7) gains one and reaches argon's 2, 8, 8. Atoms in the middle, like carbon with 4, share electrons instead of trading them, since gaining or losing 4 would cost too much energy.

In a shared bond, both atoms count the shared pair. In water, oxygen starts with 6 valence electrons. It forms 2 bonds and keeps 2 lone pairs, so it counts 2×2+2×2=8. Each hydrogen counts only its one bond, 2 electrons, and that fills its first shell, which holds just 2. This 2-electron target for hydrogen is called the duet rule.

The octet rule is a strong tendency, not a law. Boron in BF3 is stable with only 6 electrons around it. Nitrogen monoxide, NO, has 11 valence electrons, an odd number, so one atom must be left with fewer than 8. Atoms from period 3 down, such as phosphorus and sulfur, are large enough to hold more than 8: PCl5 has 10 around phosphorus and SF6 has 12 around sulfur. The rule works best for carbon, nitrogen, oxygen and fluorine, the atoms of most everyday molecules.

Think of it like this. Picture each atom's outer shell as an eight-seat van. An atom with 7 passengers picks up one more, an atom with 1 drops its passenger off with a neighbor, and a full van, like neon's, goes nowhere. The picture leaks at the edges: hydrogen's van has only 2 seats, and large atoms like sulfur can squeeze in extra passengers.

Core idea. Main-group atoms tend to lose, gain or share electrons until their outer shell holds 8, the arrangement of a noble gas; that target predicts ion charges, bond counts and formulas, with known exceptions.


When to Use

Use the octet rule to predict the ion charge of a main-group element, the number of bonds an atom forms (C 4, N 3, O 2, halogens 1), or to check a Lewis structure: every atom except hydrogen should count 8. Expect exceptions with boron, odd numbers of electrons, and central atoms from period 3 or lower. For transition metals the octet rule does not apply; use Electron Configuration.

Tip. Ask: Are you predicting an atom's ion charge or bond count from how many electrons it needs to reach eight?

How to Recognize It

Before reaching for the octet rule, check that the atom is a main-group element whose outer-shell count can be pushed to eight.

  1. Is the atom a main-group element such as C, N, O, Na or Cl, rather than hydrogen or a transition metal?

    Yes means eight is the target. Hydrogen and helium stop at two (the duet rule), and transition-metal ions such as Fe2+ are explained with Electron Configuration instead.

  2. Do you need a number the atom ends up with, such as the charge on its ion or how many bonds it makes?

    Yes fits the octet rule: for a nonmetal, 8 minus its outer electrons gives its usual bond count or negative charge. If you only need the outer count itself, that is Valence Electron.

  3. Does the central atom come from period 3 or below, or does the molecule have an odd number of electrons?

    Yes is a warning sign: sulfur holds 12 electrons in SF6 and NO has one unpaired electron, so the rule bends. Count the electrons on a full Lewis Structure instead of forcing eight.

  4. Are you asked where every bond and lone pair sits in a molecule?

    That is a Lewis Structure task. The octet rule is the check you run on each atom once the drawing is done, not the drawing itself.

Octet Rule vs Valence Electron vs Lewis Structure vs Ion

All four involve counting outer electrons, so they blur together. Separate them by what you end up with: a target number, a starting count, a drawing, or a charged particle.

Octet Rule

Meaning
The octet rule says main-group atoms tend to gain, lose or share electrons until their outer shell holds 8, the arrangement of a noble gas.
Key test
Predicts how many electrons an atom will gain, lose or share.
Example
Nitrogen has 5 outer electrons, so it shares 3 more and makes three bonds in NH3.

Valence Electron

Meaning
Valence electrons are the electrons in an atom's outermost occupied shell, the ones available for bonding.
Key test
A starting count you read from the group, before any bonding happens.
Example
Oxygen, in group 16, has 6 valence electrons.

Lewis Structure

Meaning
A Lewis structure is a diagram of a molecule or ion that shows each bonding pair as a line and each lone pair as two dots.
Key test
Produces a drawing of a whole molecule, not a single number.
Example
Ammonia drawn as N joined to three H atoms by lines, with one lone pair of dots on N.

Ion

Meaning
An ion is an atom or group of atoms that has gained or lost electrons and so carries an overall charge.
Key test
The particle has a net charge, such as +1 or −2.
Example
Mg2+ forms when magnesium loses its 2 valence electrons, leaving the arrangement of neon.

Formula & Notation

How to read it: In Lewis structures, each bond represents 2 shared electrons. Lone pairs (non-bonding pairs) also contribute to the octet count. Count: bonding electrons + lone pair electrons = 8 for a satisfied octet.

Worked Examples

Example 1 — Predict formulas and ions

Easy

Use the octet rule to predict the simplest compound of hydrogen with (a) nitrogen and (b) carbon, and the ions formed by (c) calcium and (d) oxygen.
Show the steps and the answer
  1. (a) N has 5 valence electrons and needs 3 more: it bonds to 3 H, giving NH3.

    Each bond to a hydrogen adds one shared electron to nitrogen's count: 5+3=8.

  2. (b) C has 4 and needs 4: CH4.

    Four bonds give carbon 4+4=8.

  3. (c) Ca (2, 8, 8, 2) loses 2: Ca2+.

    Losing 2 leaves argon's 2, 8, 8, which is far easier than gaining 6.

  4. (d) O has 6 and gains 2: O2−.

    6+2=8 gives neon's arrangement.

Answer: (a) NH3, (b) CH4, (c) Ca2+, (d) O2−.

Takeaway: For a nonmetal, 8 minus its valence electrons is both the number of bonds it forms and the negative charge it takes as an ion.

Example 2 — An exception: boron trifluoride

Standard

Boron has 3 valence electrons and fluorine has 7. Work out the bonding in BF3, count the electrons around boron, and decide whether BF3 obeys the octet rule.
Show the steps and the answer
  1. Total the valence electrons: 3+3(7)=24.

    A structure can use only the electrons the atoms bring.

  2. Draw three B–F single bonds (6 electrons) and give each F three lone pairs (3×6=18): 6+18=24.

    All 24 electrons are used, and each fluorine counts 2+6=8.

  3. Count around boron: 3 bonds × 2 = 6 electrons.

    Boron is two short of an octet, with no electrons left to give it.

  4. Check against behavior: BF3 readily accepts a lone pair from a molecule such as NH3, forming a B–N bond.

    That eagerness to pick up a pair is what you expect from an atom with only 6 electrons.

Answer: Boron has only 6 electrons in BF3: it is a stable exception to the octet rule, and it readily accepts a pair (for example from NH3) to reach 8.

Takeaway: Boron compounds often have fewer than 8 electrons around boron; treat the octet rule as a guide, not a law.

Example 3 — Find the mistake: an octet for hydrogen

Application

Ria draws water as H–O–H and then adds three lone pairs to each hydrogen "so every atom has an octet." Find the mistake and correct it.
Show the steps and the answer
  1. Count the valence electrons available: 2(1)+6=8.

    A Lewis structure can contain only the electrons the atoms bring.

  2. Count Ria's drawing: 2 bonds (4 electrons) plus 6 lone pairs on hydrogen (12 electrons) is 16, before any on oxygen.

    She has used at least 8 electrons that do not exist.

  3. Apply the duet rule: each hydrogen is full with its one bond, 2 electrons.

    Hydrogen's only shell, n=1, holds 2.

  4. Place the remaining 4 electrons as 2 lone pairs on oxygen: 4+4=8 for oxygen.

    Now the total is 8 and every atom has a full shell.

Answer: Water is H–O–H with no lone pairs on hydrogen and two lone pairs on oxygen: 8 valence electrons in total, oxygen with an octet and each hydrogen with 2.

Takeaway: Hydrogen is full at 2 electrons; always check a structure against the total valence electron count.

Where You'll See It

  • Why sodium and chlorine 'want' each other

    Sodium has 1 too many electrons for a full octet and chlorine is 1 short; sodium gives one away and chlorine takes it, so both end with a stable 8 — that's the octet rule driving the bond.

  • Noble gases as the goal everyone copies

    Neon and argon already have 8 valence electrons and never react; every other atom bonds to imitate that full-octet stability, which is why the octet rule predicts so many formulas.

  • Counting dots to predict a formula

    Oxygen has 6 valence electrons and needs 2 more, so it grabs 2 hydrogens — the octet rule lets you predict H2O before ever seeing the molecule.

Common Mistakes

  1. The slip: Every atom needs exactly 8 electrons, including hydrogen.

    Why it's tempting: The rule is literally called the 'octet' (8) rule, so students apply 8 to everything.

    Instead: Hydrogen and helium follow the duet rule — they're stable with 2 electrons (a full first shell), not 8. The octet target applies to atoms whose valence shell is the second shell or beyond.

  2. The slip: The octet rule has no exceptions; all molecules obey it.

    Why it's tempting: It works for the common molecules taught first (water, methane, ammonia), so it seems universal.

    Instead: There are real exceptions: BF3 leaves boron with only 6 electrons, NO has an odd electron, and period-3+ atoms like sulfur and phosphorus can expand their octet to 10 or 12.

  3. The slip: Sodium (2, 8, 1) gains 7 electrons to complete its octet, forming Na7−.

    Why it's tempting: The rule is stated as reaching 8, and adding electrons to the outer shell until it holds 8 looks like the direct route.

    Instead: Losing 1 electron empties shell 3 and leaves the full shell 2 (2, 8), neon's arrangement, which costs far less energy than gaining 7, so sodium forms Na+. Metals with 1, 2 or 3 valence electrons usually lose them; nonmetals with 5, 6 or 7 usually gain or share.


Mini Practice

Try these on your own. Tap Reveal when you want to check.

  1. To reach an octet, how many electrons does each atom gain or lose: sodium (1 valence electron), sulfur (6), aluminium (3)?

    Hint: Each atom takes the shorter route to a full set of 8.

  2. Nitrogen has 5 valence electrons and forms 3 bonds in NH3. How many lone pairs does nitrogen have, and does it have an octet?

    Hint: Count nitrogen's bonding electrons, then see how many of its own are left.

  3. In CH4, count the electrons around carbon and around each hydrogen.

    Hint: Each C–H bond is one shared pair, counted for both atoms.

  4. In BF3, boron forms three single bonds and has no lone pairs. How many electrons surround boron? Does it obey the octet rule?

    Hint: Count the electrons in boron's three bonding pairs.

  5. In SF6, sulfur forms 6 single bonds. Does the octet rule describe sulfur here, or is this an expanded octet?

    Hint: Count the electrons around sulfur, and recall which period sulfur is in.

  6. A student draws H2O and adds lone pairs to each hydrogen so that every atom has 8 electrons. What is wrong?

    Hint: How many electrons fill hydrogen's only shell?

Want the full set?

50 practice questions for this concept — free to try, every one with a complete worked solution showing the why, not just the answer.

Frequently Asked Questions

Why is eight the special number and not some other count?

Eight is what fills one s subshell (2 electrons) and one p subshell (6 electrons) in the outer shell. With both full, the atom has the same arrangement as a noble gas, and adding or removing one more electron costs a lot of energy. That is why the rule works best in periods 2 and 3 and fails for transition metals, whose d subshells can take up to 10 more electrons.

If sodium reaches eight by losing one electron, why does it not lose a second one?

Once sodium loses its single 3s electron, the shell underneath is a complete set of 8 (the 2s and 2p electrons). Pulling one more electron out of that full inner shell takes about nine times as much energy as removing the first, roughly 4,560 kJ/mol against 496 kJ/mol, which no ordinary compound pays back. So sodium stops at Na+\text{Na}^+.

How can a molecule like BF3 exist if boron ends up with only six electrons?

Boron starts with 3 valence electrons and makes three bonds to fluorine, ending with 6. Adding a double bond to reach eight would give fluorine, the most electronegative element, a positive formal charge, which is worse. So BF3\text{BF}_3 stays electron-short and eagerly accepts a lone pair from another molecule: with ammonia it forms F3B–NH3\text{F}_3\text{B–NH}_3, and only then does boron have eight.

Do noble gases ever give up their own full octet?

The light ones do not, but the heavier ones can. In 1962 Neil Bartlett made the first noble-gas compound, and xenon is now known to form XeF2\text{XeF}_2, XeF4\text{XeF}_4 and XeF6\text{XeF}_6. Xenon's outer electrons are far from its nucleus and well shielded, so a strong electron-puller like fluorine can draw them into bonds. Helium, neon and argon form no stable compounds under ordinary conditions.

Learning Path

← Before

Valence Electron
Octet Rule

You are here

Next →

Lewis Structure
You need Valence Electron first, since the octet rule is about the outer-shell count. This concept adds the target of 8 (2 for hydrogen) and the three ways to reach it: lose, gain or share. Next, Lewis Structure uses the rule to place every bonding pair and lone pair in a molecule.

See Also