A crystal's load capacitors
What a crystal's load capacitance CL is, why the two external capacitors are needed, how to size them from the stray capacitance, and what happens when the value is wrong.
A crystal does not oscillate “in mid-air”: it oscillates at its nominal frequency only when it sees a precise capacitance at its terminals — the datasheet load capacitance CL. You provide that capacitance, with two external capacitors. Getting them wrong is the most common and silent mistake in clock design: the oscillator still starts, but off frequency. This tool sizes them; this page explains how and why.
What load capacitance is
The load capacitance (CL) is the capacitance the crystal must “feel” between its two pins to resonate at the frequency printed on the label. It is a property of the crystal, not a free value: a 12 pF and an 18 pF crystal, at the same nominal frequency, need different load networks. Typical values lie between 8 and 20 pF.
That capacitance is not inside the crystal: you supply it externally, with two capacitors (one per branch, to ground) in the typical Pierce topology used by almost every microcontroller.
Why two capacitors, and the formula
The two external capacitors C1 and C2 are, from the crystal’s point of view, in series (their common node is AC ground). To that series the stray capacitance of traces and pins is added. The load capacitance seen by the crystal is therefore:
In the usual case of equal capacitors (C1 = C2 = C) the series equals C/2, and the formula simplifies:
Example: a crystal with CL = 12 pF on a layout with C_stray ≈ 3 pF (lumped value) needs C1 = C2 = 2·(12 − 3) = 18 pF. If you ignore the stray and fit 24 pF “because 12·2”, the effective load becomes 24/2 + 3 = 15 pF instead of 12: the crystal runs with +3 pF of load and the frequency shifts.
Typical values (C_stray ≈ 3 pF lumped)
| Crystal CL | C1 = C2 = 2·(CL − C_stray) |
|---|---|
| 8 pF | 10 pF |
| 10 pF | 14 pF |
| 12 pF | 18 pF |
| 18 pF | 30 pF |
| 20 pF | 34 pF |
The table holds only for that stray value: change the layout (or the MCU package) and the numbers move. This is why there is no “universal 22 pF cap” — the right value depends on your crystal’s CL and your PCB.
Estimating C_stray
The per-branch stray capacitance sums two contributions:
- PCB traces between capacitor, crystal and chip pin: keep them short and symmetric, with a grounded guard ring under the crystal. Typically 1–3 pF.
- Package pin (OSC_IN / OSC_OUT): often given in the MCU datasheet as the oscillator-pin capacitance. Typically 1–3 pF.
With no precise data, 2–5 pF is a reasonable estimate for a careful layout. The tool has a separate field for the MCU-pin contribution, if you want to keep it distinct from the PCB one: the two are summed.
Careful: lumped, not per branch
There is a semantic trap here worth a few pF, that is tens of ppm. In the application-note formula C_stray is a stray capacitance lumped across the crystal terminals, added to CL just once. A genuinely per-branch stray to ground — the capacitance of a single trace, the one you measure or simulate — sits instead in parallel with C1 and with C2, and then the series becomes:
that is, it contributes half. If you measure 3 pF on each trace and type that as C_stray, you ask the calculation for 3 pF of correction where 1.5 pF is needed: the capacitors come out 3 pF smaller and the effective CL 1.5 pF lower, which at 11 ppm/pF is 16 ppm in the wrong direction. The rule that keeps you out of trouble: the field takes (pin-to-pin coupling) + (per-branch stray)/2, and the typical 2–5 pF of the application notes is already expressed in that form.
What getting it wrong costs: pulling, computed
If the effective load capacitance departs from CL, the crystal frequency shifts — the phenomenon is called pulling. The sensitivity in ppm/pF is often tabulated in the datasheet, but there is no need to take it on trust: it follows from the two equivalent-circuit parameters every datasheet gives, the static capacitance C₀ (a few pF, in parallel with the motional branch) and the motional capacitance C_m (a few femtofarad). The loaded resonance frequency and its derivative are:
| C_m (motional) | C₀ (static) | CL 8 pF | CL 10 pF | CL 12 pF | CL 16 pF | CL 20 pF |
|---|---|---|---|---|---|---|
| 3 fF | 2 pF | 15.00 | 10.42 | 7.65 | 4.63 | 3.10 |
| 5 fF | 3 pF | 20.66 | 14.79 | 11.11 | 6.93 | 4.73 |
| 8 fF | 4 pF | 27.78 | 20.41 | 15.63 | 10.00 | 6.94 |
| 15 fF | 5 pF | 44.38 | 33.33 | 25.95 | 17.01 | 12.00 |
| 20 fF | 7 pF | 44.44 | 34.60 | 27.70 | 18.90 | 13.72 |
Two readings. First: the sensitivity sits between 3 and 45 ppm/pF, so one pF of error already costs more than the typical tolerance of a timekeeping crystal (±20 ppm). Second, less obvious: the sensitivity goes as 1/(C₀ + CL)², that is a low-CL crystal is far twitchier. Between CL = 8 and CL = 20 pF the factor is about 4: the same layout error, on the same PCB, moves the frequency four times as much. This is why 6–8 pF crystals demand a much more disciplined layout than 18–20 pF ones, and not the other way round as the “less capacitance = fewer problems” intuition would suggest.
The hierarchy of errors
Lined up, the contributions to the CL error carry very different weight — and the one people tend to think about (E-series rounding) is not the first:
| Error source | Typical size | Effect on CL | ppm at 11 ppm/pF |
|---|---|---|---|
| stray estimate off by 1 pF | ±1 pF | ±1.00 pF | ±11.1 |
| capacitor tolerance ±5 % (18 pF) | ±0.90 pF | ±0.45 pF | ±5.0 |
| E24 rounding (worst case in the table) | −1.5 pF | −0.75 pF | +8.3 |
| capacitor tolerance ±2 % (18 pF) | ±0.36 pF | ±0.18 pF | ±2.0 |
| temperature coefficient of a C0G | ±0.06 pF | ±0.03 pF | ±0.3 |
First place goes to the stray estimate, which is also the only entry that cannot be checked after the fact without instruments. That flips the practical priority: first take care of the layout (short symmetric traces, a ground guard ring, nothing else under the crystal) and look up the pin capacitance in the MCU datasheet; then it makes sense to argue about 18 pF versus 20 pF, and only last about 2 % versus 5 % tolerance.
And in time, how much is that
For a 32.768 kHz RTC — the case where pulling is visible to the naked eye — ppm translate like this:
| Error | s/day | s/month | min/year |
|---|---|---|---|
| 1 ppm | 0.09 | 2.6 | 0.5 |
| 5 ppm | 0.43 | 13.0 | 2.6 |
| 10 ppm | 0.86 | 25.9 | 5.3 |
| 20 ppm | 1.73 | 51.8 | 10.5 |
| 50 ppm | 4.32 | 129.6 | 26.3 |
| 100 ppm | 8.64 | 259.2 | 52.6 |
One single pF of load error on an 11 ppm/pF crystal is therefore worth about a second a day: a clock that loses half a minute a month with nothing “broken” anywhere.
The consequences:
- Drifting timing. An RTC off by 20 ppm accumulates about 1.7 seconds per day. In a UART or a bus the clock error adds to the baud error and can drop frames.
- Interoperability. Protocols with tight clock tolerances (USB, Ethernet, CAN) may fall outside the allowed window.
- EMC. An off-frequency clock moves the spectral lines of the emissions; in an electromagnetic-compatibility test a line that moves may land where one used to pass, or vice versa. A badly loaded oscillator is a silent way to fail a pre-compliance run.
Choosing E-series values
Capacitors only come in standard values (E-series): E12 has 12 values per decade (10% tolerance), E24 has 24 (5%). The computed ideal value almost never matches a standard one, so you pick the nearest and check the resulting error on the effective CL. The tool shows both the nearest E12 and E24 values, and computes the effective CL on E24 — the finer series, the one you would use for a precision capacitor.
| CL | ideal C | E12 | E24 | effective CL (E24) | error | ppm |
|---|---|---|---|---|---|---|
| 8 pF | 10.0 | 10 | 10 | 8.00 pF | 0.00 % | 0.0 |
| 10 pF | 14.0 | 15 | 13 | 9.50 pF | −5.00 % | +7.4 |
| 12 pF | 18.0 | 18 | 18 | 12.00 pF | 0.00 % | 0.0 |
| 16 pF | 26.0 | 27 | 27 | 16.50 pF | +3.13 % | −3.5 |
| 18 pF | 30.0 | 27 | 30 | 18.00 pF | 0.00 % | 0.0 |
| 20 pF | 34.0 | 33 | 33 | 19.50 pF | −2.50 % | +2.4 |
One case deserves a note: CL = 10 pF asks for 14 pF, which does not exist in E24 (between 13 and 15, equidistant). The value picked is 13 pF and the effective CL drops to 9.5 pF, −5 %: the worst row in the table. With 15 pF it would go to 10.5 pF, +5 %, symmetric — and in that case the choice is made on the sign, not the magnitude, because it is preferable to sit above the nominal CL (more load → lower frequency, a more comfortable oscillation margin) than below it.
In order of magnitude, though, rounding is not the problem: the worst row in the table is worth 8 ppm, less than the tolerance of the capacitor itself.
When the computed value is of no use
There is a region where the formula returns a positive number you cannot use. Below 4 pF the typical uncertainty on the stray (±1 pF) is a quarter of the value: the effective CL depends more on the layout than on the component, and the design does not repeat from one board to the next. The tool flags this without hiding the result — it is not a specification limit, it is a reproducibility threshold.
| Crystal CL | stray 3 pF | stray 5 pF | stray 6 pF |
|---|---|---|---|
| 6 pF | 6.0 pF | 2.0 ⚠ pF | impossible |
| 8 pF | 10.0 pF | 6.0 pF | 4.0 pF |
| 10 pF | 14.0 pF | 10.0 pF | 8.0 pF |
| 12 pF | 18.0 pF | 14.0 pF | 12.0 pF |
| 16 pF | 26.0 pF | 22.0 pF | 20.0 pF |
The 6 pF stray column is why a CL = 6 pF crystal has to be chosen together with the layout and not after it: on a mediocre PCB no capacitor exists that will make it run on frequency.
Limitations
- The model assumes the two capacitors are equal (C1 = C2), the standard case of a crystal Pierce oscillator.
- It sizes the load capacitance only: it does not assess the drive level, the crystal ESR, the oscillator negative resistance or the oscillation margin — checks that need the crystal parameters and sometimes a measurement. The two are linked, though: the load capacitors sit in the feedback path, so raising them lowers the loop gain and tightens the oscillation margin, while the power dissipated in the crystal grows with the square of CL, P = ESR·(2πf·C_L·V_rms)²:
| ESR | CL | V rms across the crystal | Dissipated power |
|---|---|---|---|
| 30 Ω | 12 pF | 0.5 V | 2.7 µW |
| 30 Ω | 12 pF | 1.0 V | 10.9 µW |
| 80 Ω | 12 pF | 1.0 V | 29.1 µW |
| 50 Ω | 20 pF | 1.2 V | 72.8 µW |
With a typical maximum of 100 µW for a small SMD part, the 72.8 µW row is already close to the limit: overdriving a crystal does not just push it off frequency, it ages it. The classic oscillation-margin criterion — oscillator negative resistance at least 5 times the crystal’s maximum ESR — has to be checked separately, and on high-ESR crystals (32.768 kHz, typically tens of kΩ) it is often the constraint that decides, not the CL.
- The pulling in ppm is not computed by the tool, because it needs the crystal’s C₀ and C_m as user input: the sensitivity section shows how to work it out by hand from the datasheet.
- Drive level and oscillation margin are not evaluated: those are checks on the amplifier, not on the load network.
References
- Vendor application notes — both microcontroller and crystal vendors publish application notes on Pierce oscillator design, load-capacitance selection and oscillation-margin calculation. They are the operational reference for the real case.
- Related tool — the load-capacitor calculator puts this page into practice: enter CL and stray capacitances and get the two caps, the E-series value and the error.
A similar project?
Acoustics, embedded, calculation tools: if you have a related use case, let’s talk.