You met pH and pOH as a scale from 0 to 14. Here we compute them exactly with logarithms, starting with strong acids and bases, which ionize completely.
🔑 Key idea
$\text{pH} = -\log[\mathrm{H_3O^+}]$, $\text{pOH} = -\log[\mathrm{OH^-}]$, and at $25\ ^\circ\text{C}$, $[\mathrm{H_3O^+}][\mathrm{OH^-}] = K_w = 1.0 \times 10^{-14}$, so $\text{pH} + \text{pOH} = 14.00$. A strong acid gives $[\mathrm{H_3O^+}]$ equal to its concentration; a strong base gives $[\mathrm{OH^-}]$ equal to its concentration times the number of $\mathrm{OH^-}$ per formula unit.
💡 Why it works
Water ionizes slightly: $\mathrm{2H_2O \rightleftharpoons H_3O^+ + OH^-}$, with $K_w = [\mathrm{H_3O^+}][\mathrm{OH^-}]$. Taking $-\log$ of both sides turns the product into a sum: $\text{pH} + \text{pOH} = \text{p}K_w = 14.00$. The strong acids ($\mathrm{HCl}$, $\mathrm{HBr}$, $\mathrm{HI}$, $\mathrm{HNO_3}$, $\mathrm{HClO_4}$ and the first proton of $\mathrm{H_2SO_4}$) give up their protons completely, so no equilibrium calculation is needed. The strong bases are the Group 1 hydroxides and $\mathrm{Ca(OH)_2}$, $\mathrm{Sr(OH)_2}$ and $\mathrm{Ba(OH)_2}$, which release two $\mathrm{OH^-}$ each.
Move the pointer: each step of 1 in pH is a factor of 10 in $[\mathrm{H_3O^+}]$, and pH + pOH stays 14 at 25 °C.
Worked examples
✏️ Worked example: A strong acid
Find the pH of $0.0050\ \text{M}$ $\mathrm{HNO_3}$.
What is the pH of $1.0 \times 10^{-8}\ \text{M}$ HCl? (It is not 8.00.)
An acid cannot make water basic. At this dilution water's own ionization matters: the charge balance is $$[\mathrm{H_3O^+}] = [\mathrm{Cl^-}] + [\mathrm{OH^-}] = 1.0 \times 10^{-8} + \dfrac{K_w}{[\mathrm{H_3O^+}]}$$
With $h = [\mathrm{H_3O^+}]$: $h^2 - (1.0 \times 10^{-8})h - 1.0 \times 10^{-14} = 0$, so $h = 1.05 \times 10^{-7}\ \text{M}$ and $\text{pH} = 6.98$.
Answer: $\text{pH} = 6.98$, just on the acidic side of neutral.
$K_w$ depends on temperature, so "neutral" is pH 7.00 only at $25\ ^\circ\text{C}$. Neutral always means $[\mathrm{H_3O^+}] = [\mathrm{OH^-}]$:
Kw rises with temperature (water ionizes endothermically), so neutral water is below pH 7 when hot.
Temperature
$K_w$
pH of pure water
0 °C
$1.1 \times 10^{-15}$
7.48
25 °C
$1.0 \times 10^{-14}$
7.00
37 °C
$2.4 \times 10^{-14}$
6.81
50 °C
$5.5 \times 10^{-14}$
6.63
100 °C
$5.1 \times 10^{-13}$
6.15
⚠️ Common mistake
Dropping the minus sign (pH would come out negative for any ordinary acid) or forgetting that $\mathrm{Ba(OH)_2}$ gives two hydroxide ions. Check: an acid must give pH below 7 (at 25 °C), a base above, and doubling a concentration changes the pH by only 0.30.
See the scale with real liquids in the Mixing Lab, where you can test kitchen liquids with four indicators.