Every formula, and where it comes from
The calculator is a thin layer over a small, open formula library. This page is that library written out. Conventions are labelled as conventions; constants carry their source.
Saponification and lye
The formula, and where it comes from
SAP_NaOH (mg/g) = SAP_KOH × 39.997 ÷ 56.106 # molar masses, IUPAC 2013 KOH₁₀₀ (g) = Σ oilᵢ (g) × SAP_KOHᵢ ÷ 1000 # SAP defined as mg KOH per g fat KOH_sf = KOH₁₀₀ × (1 − superfat ÷ 100) NaOH to weigh = KOH_sf × (1 − f_KOH) × 39.997 ÷ 56.106 ÷ (purity_NaOH ÷ 100) KOH to weigh = KOH_sf × f_KOH ÷ (purity_KOH ÷ 100) superfat from a given lye = (1 − lye_supplied_KOHeq ÷ KOH₁₀₀) × 100
- AOCS Official Method Cd 3-25, "Saponification Value of Fats and Oils". American Oil Chemists' Society. Defines SAP as mg KOH required to saponify 1 g of sample.
- IUPAC Commission on Isotopic Abundances and Atomic Weights, "Atomic weights of the elements 2013" (Pure Appl. Chem. 88(3), 2016). Na 22.990, K 39.098, O 15.999, H 1.008 → NaOH 39.997 g/mol, KOH 56.106 g/mol.
- Dunn, Kevin M. Scientific Soapmaking: The Chemistry of the Cold Process. Clavicula Press, 2010. Chapters on saponification stoichiometry, lye discount and lye purity.
Water, three ways, and master batches
The formula, and where it comes from
water = oils × p ÷ 100 # p = water as % of oils (38 is the old default) water = lye × (100 − c) ÷ c # c = lye concentration % (33 is our default) water = lye × r # r = water : lye ratio c = lye ÷ (lye + water) × 100; r = water ÷ lye; p = water ÷ oils × 100 Master batch at strength s %: solution = lye ÷ (s ÷ 100); water_in = solution − lye; water_add = water − water_in Liquids replacing water: plain water = max(0, water − Σ liquidᵢ × water%ᵢ ÷ 100)
- Dunn, Kevin M. Scientific Soapmaking: The Chemistry of the Cold Process. Clavicula Press, 2010. Lye solution concentration and its effect on trace and gel.
- Community convention: "full water" = 38 % of oil weight, the default that most hobby calculators have used since the 2000s; roughly a 27–28 % lye solution for a typical bar recipe. — A convention, not a chemical constant. Lye concentration is the better control variable because it does not drift with the oil blend.
Acids and fatty liquids
The formula, and where it comes from
NaOH consumed (g) = mass × purity × n × 39.997 ÷ M_acid citric acid (anhydrous, triprotic, M 192.124): 0.6246 g NaOH per g (0.8760 g KOH) citric acid monohydrate (M 210.139): 0.5710 acetic acid (M 60.052): 0.6660 → 5 % vinegar: 0.0333 per g lactic acid (M 90.078): 0.4440 effective superfat = (oils × sf ÷ 100 + fat from milks) ÷ (oils + fat from milks) × 100
- IUPAC 2013 atomic weights. Molar masses: citric acid C₆H₈O₇ 192.124 g/mol (monohydrate 210.139), acetic acid C₂H₄O₂ 60.052, lactic acid C₃H₆O₃ 90.078, NaOH 39.997, KOH 56.106.
- Neutralisation stoichiometry: citric acid is triprotic (3 OH⁻ per molecule); acetic and lactic acids are monoprotic. g NaOH per g acid = n × 39.997 ÷ M_acid.
- USDA FoodData Central, SR Legacy: Milk, whole, 3.25 % milkfat (FDC 171265): water 88.1 %, fat 3.25 %. Milk, goat, fluid (FDC 171278): water 87.0 %, fat 4.14 %. Cream, heavy whipping (FDC 170859): water 57.7 %, fat 36.1 %.
Deriving a saponification value from composition
The formula, and where it comes from
M̄_fatty acid = Σ(fraction_i × M_i) # mass-weighted, renormalised to 100 % M_triglyceride = 3 × M̄_fatty acid + 38.03 # glycerol 92.094 less three waters SAP (mg KOH/g) = 3 × 56 106 ÷ M_triglyceride # three KOH per triglyceride free fatty acids (stearic acid, lauric acid and the like) take one KOH each: SAP = 56 106 ÷ M̄_fatty acid Validated on the 35 Codex oils where the saponification range and the fatty-acid ranges come from the same standard: median absolute error 0.90 % 90th percentile 2.74 % worst 5.18 % bias −0.01 % A derived value therefore carries a ±3 % band, and is offered only where the published profile sums to between 95 % and 115 %.
- Saponification stoichiometry: one mole of triglyceride consumes three moles of KOH. SAP (mg KOH/g) = 3 × 56 106 ÷ M_triglyceride, where M_triglyceride = 3 × M̄_fatty acid + 38.03 (glycerol 92.09 less three waters at 18.015).
- Fatty-acid molar masses from their molecular formulae with IUPAC 2013 atomic weights (C 12.011, H 1.008, O 15.999).
- AOCS Official Method Cd 3-25: the saponification value of a specific lot is measured by titration. A certificate of analysis replaces the published range with a figure for the fat in front of you.
How well the published data pins the lye down
The formula, and where it comes from
KOH_low = Σ(oilᵢ × SAP_minᵢ ÷ 1000) # every oil at the bottom of its published range KOH_high = Σ(oilᵢ × SAP_maxᵢ ÷ 1000) # ...and at the top KOH_mid = Σ(oilᵢ × SAP_repᵢ ÷ 1000) # what the lye is actually weighed from supplied (as KOH equivalent) = KOH_mid × (1 − sf ÷ 100) superfat actually achieved: worst case = (1 − supplied ÷ KOH_low) × 100 # fat needs LESS lye than was weighed best case = (1 − supplied ÷ KOH_high) × 100 # fat needs MORE, so more is left unsaponified smallest nominal superfat whose worst case clears a floor f: sf ≥ (1 − (1 − f) × KOH_low ÷ KOH_mid) × 100
- Codex Alimentarius CXS 210-1999, Standard for Named Vegetable Oils, and CXS 211-1999 for animal fats: saponification value is published as a range per named oil, not a single figure, because the property varies with origin, season and processing.
- Worst-case bound: every oil is taken at the same end of its published range simultaneously. Real lots are not perfectly correlated, so the achievable spread is narrower. — This is not a confidence interval and implies nothing about how likely either end is. It is the limit of what the published data permits.
- AOCS Official Method Cd 3-25: the saponification value of a specific lot is measured by titration. A certificate of analysis replaces the published range with a figure for the fat in front of you.
Fatty-acid profile, soap qualities, iodine and INS
The formula, and where it comes from
profile = Σ (oilᵢ ÷ total oils) × fatty acidsᵢ # mass-weighted percent hardness = lauric + myristic + palmitic + stearic (29–54) cleansing = lauric + myristic (12–22) conditioning = oleic + linoleic + linolenic + ricinoleic (44–69) bubbly = lauric + myristic + ricinoleic (14–46) creamy = palmitic + stearic + ricinoleic (16–48) iodine value = Σ wᵢ × IVᵢ (41–70) INS = Σ wᵢ × (SAP_KOHᵢ − IVᵢ) (136–165, ideal 160)
- Community convention for soap qualities, in continuous use in hobby lye calculators since c. 2005: hardness = lauric + myristic + palmitic + stearic; cleansing = lauric + myristic; conditioning = oleic + linoleic + linolenic + ricinoleic; bubbly lather = lauric + myristic + ricinoleic; creamy lather = palmitic + stearic + ricinoleic. Recommended bands: hardness 29–54, cleansing 12–22, conditioning 44–69, bubbly 14–46, creamy 16–48. — A convention, not a measurement. It ignores superfat, water, cure and additives, and treats every fatty acid in a group as equal.
- AOCS Official Method Cd 1-25, "Iodine Value of Fats and Oils, Wijs Method". g I₂ absorbed per 100 g of fat; a measure of unsaturation.
- McDaniel, Robert S. Essentially Soap. Krause Publications, 2000. INS = saponification value (mg KOH/g) − iodine value; recommended range 136–165, ideal 160.
Fragrance load, IFRA and allergens
The formula, and where it comes from
f = oils × p ÷ 100 # p = % of oils (PPO) f = base × p ÷ (100 − p) # p = % of finished batch; base = everything but fragrance % of finished product = f ÷ (base + f) × 100 ≤ certificate maximum for the product's IFRA category blends (conservative): Σ loadᵢ ÷ maxᵢ ≤ 1 allergen % in product = Σ (fragrance % × allergen % in fragrance ÷ 100) ÷ (1 − cure mass loss) declare if > 0.001 % leave-on, > 0.01 % rinse-off
- IFRA, "Guidance for the use of IFRA Standards", 51st Amendment (June 2023), Table 11 product-category mapping and §6 on calculating the concentration of a fragrance mixture in a finished product. — IFRA Standards are voluntary; limits are maximum concentrations in the finished product; a Certificate of Conformity is issued by the fragrance supplier, not by IFRA.
- Regulation (EC) No 1223/2009, Annex III, as amended by Regulation (EU) 2023/1545: fragrance allergens must be named in the ingredient list when their concentration exceeds 0.001 % in leave-on products or 0.01 % in rinse-off products.
Mold sizing
The formula, and where it comes from
V (mL) = l × w × h | π (d ÷ 2)² h | cavities × volume each # 1 in³ = 16.387064 mL batch (g) = V × ρ × fill # ρ ≈ 1.0 g/mL, calibrate oils = batch ÷ (1 + lye/oil + water/oil + additives/oil + fragrance/oil) for comparison: the "in³ × 0.4 oz" rule assumes full water and 5 % superfat
- Volume of a rectangular prism V = l × w × h; of a cylinder V = π × (d ÷ 2)² × h. 1 in³ = 16.387064 mL.
- Empirical default. Fresh cold-process soap batter has a density close to water, ≈ 0.95–1.0 g/mL; the community rule "in³ × 0.4 = oz of oils" implies about 0.69 g/mL of oils, which is ≈ 1.05 g/mL of batter at 38 % water and 5 % superfat. Calibrate by weighing a filled mold once. — Density varies with whipping, fragrance, temperature and how full the mold is poured. Treat the default as a starting point and calibrate.
Liquid soap dilution
The formula, and where it comes from
solids = oils + pure KOH # mass is conserved in saponification paste concentration = solids ÷ paste × 100 water to add = solids ÷ (target ÷ 100) − paste
- Conservation of mass in saponification: the soap and glycerol formed weigh exactly what the fat and hydroxide weighed. Solids in a paste are therefore taken as oils + pure lye; the remainder is water.
- Failor, Catherine. Making Natural Liquid Soaps. Storey Publishing, 2000. Paste method, dilution ratios and sequestering.
Where a derived saponification value comes from
12 oils in the database have no saponification value in any primary document we could use. Rather than leave them out of the calculator or invent a number, the figure is calculated from the oil's own measured fatty-acid composition. That is not a guess: three moles of hydroxide saponify one mole of triglyceride, and the molar mass of the triglyceride follows from the chain lengths of the acids in it. Composition determines the value.
The question is how accurate it is, and that is measurable. The fair test is the Codex subset of the database, thirty-five named oils where the saponification range and the fatty-acid ranges were published by the same body from the same material. Against those, the method's median absolute error is 0.90 %, its ninetieth percentile 2.74 %, its worst case 5.18 %, and its bias essentially nil at −0.01 %. The median published range in the same database is ±2.9 % of its own centre, so a derived value is about as well determined as one read off a standard.
Measured against the rest of the database the apparent error is far worse — a median of 2.5 % and a worst case of 21 %. That is not the method failing. The largest disagreements are the same records the consistency check already flags as internally contradictory, where a published saponification value sits beside a composition that cannot produce it. Comparing against those conflates method error with data error, which is why the validation uses the Codex subset alone.
Every derived value is labelled as derived wherever it appears, carries a ±3 % band into the uncertainty panel, and is set aside entirely the moment you enter a measured value from your own lot.
Why the lye carries a range
A saponification value is not a constant. Codex gives coconut oil 248–265 mg KOH/g because the fat genuinely varies with origin, season and refining. Every soap calculator hides that by printing one number to one decimal place, which is false precision: the figure looks like a measurement of your oil and is really the midpoint of somebody else's survey.
Carried through, the band lands on the number that matters. Superfat is the margin between a mild bar and a caustic one, and it is exactly what the uncertainty eats. A recipe asking for 3 % superfat on ordinary olive and coconut oil can really be anywhere from −0.2 % to 6 %, and the negative end is a lye-heavy bar. That is not a reason to distrust the arithmetic; it is the reason the craft settled on about 5 % superfat, and as far as we can tell no calculator has ever shown the working behind that habit.
Taking every oil at the same end of its range at once is a bound, not a confidence interval. Real lots are not perfectly correlated, so the achievable spread is narrower, and the arithmetic says nothing about how likely either end is. The only thing that collapses it is a measurement: enter the saponification value from your lot's certificate of analysis and that oil stops contributing any uncertainty at all.
Conventions we label as conventions
The five "soap qualities" are sums of fatty-acid groups compared with bands that hobby calculators have used since the mid-2000s. They are useful for comparing recipes and useless for predicting an actual bar: they ignore superfat, water, cure, additives and process, and treat every acid in a group as equal. The 38 % "full water" default and the "× 0.4" mold rule are habits, not chemistry. We implement all of them exactly because makers compare in that language, and we say what they are.
Know when the workbench lands
Saved recipes, versions and a batch log are what comes next. Leave an address and you will hear when they are ready, plus a short note whenever something ships. No newsletter, nothing sold, one click to stop.