🔬 Lewis Structure Visualizer

Generate Lewis dot structures for any molecule. The tool counts valence electrons, places atoms, distributes lone pairs, and checks the octet rule automatically.

Quick:
PubChem structure of Water

Source: PubChem · Click to view details

Compound Information

FormulaH2O
PubChem CID962
Molecular Weight18.015 g/mol
IUPAC NameWater
View full PubChem record →

How the Algorithm Works

  1. Count valence electrons — sum of valence electrons for each atom.
  2. Identify the central atom — the element with the lowest electronegativity (excluding hydrogen).
  3. Connect atoms — single bonds between the central atom and surrounding atoms.
  4. Distribute remaining electrons — fill octets of terminal atoms first, then the central atom.
  5. Form multiple bonds — if the central atom lacks an octet, convert lone pairs into double/triple bonds.
  6. Calculate formal charges — verify the most stable structure.

Examples to Try