{
  "schemaVersion": 1,
  "slug": "sourdough-hydration-calculator",
  "category": "cooking",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "2c6075c6a0dc175f22a93e29c565afc7d0e1585bafbc63e644640ddb794552f1",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/sourdough-hydration-calculator.json",
    "src/engine.js"
  ],
  "runtimeSource": "/sources/engine.txt",
  "runtimeHash": "5c888d8898afbdee36267bb9977829e1e2ac568f6677c8ee87469c139864645c",
  "scope": "The compute function records implemented equations, constants, lookup tables and custom rules. Inputs record defaults and allowed values; outputs record precision and units. Defaults are examples, not recommendations. General background references are not evidence for this specific algorithm.",
  "publishedFormula": {
    "formula": "H = (w + S − S÷(1+p÷100)) ÷ (F + S÷(1+p÷100)) × 100",
    "vars": [
      [
        "F",
        "Flour added (g)"
      ],
      [
        "w",
        "Water added (g)"
      ],
      [
        "S",
        "Starter (g)"
      ],
      [
        "p",
        "Starter hydration (%)"
      ]
    ],
    "note": "Starter flour = starter mass ÷ (1 + starter hydration); starter water is the remainder. True hydration = total water ÷ total flour × 100; it is undefined when total flour is zero."
  },
  "externalEvidence": {
    "reviewedAt": "2026-10-12",
    "sources": [
      {
        "name": "King Arthur Baking — Baker’s percentages and hydration",
        "url": "https://www.kingarthurbaking.com/pro/reference/bakers-percentage"
      }
    ],
    "referenceRole": "definition",
    "implementationHash": "2c6075c6a0dc175f22a93e29c565afc7d0e1585bafbc63e644640ddb794552f1",
    "basis": "H = (w + S − S÷(1+p÷100)) ÷ (F + S÷(1+p÷100)) × 100",
    "limitations": "The references explain definitions and methods; any extra preset must be checked against the assumptions on this page."
  },
  "contract": {
    "compute": "const starterFlour = starterGrams/(1+starterHydration/100); const starterWater = starterGrams - starterFlour; const tf = flourGrams + starterFlour; const tw = waterGrams + starterWater; return { trueHydration: tf>0 ? tw/tf*100 : null, totalFlour: tf, totalWater: tw, doughWeight: tf+tw };",
    "inputs": [
      {
        "name": "flourGrams",
        "type": "number",
        "default": 500,
        "min": 0,
        "max": 100000,
        "step": 10
      },
      {
        "name": "waterGrams",
        "type": "number",
        "default": 375,
        "min": 0,
        "max": 100000,
        "step": 10
      },
      {
        "name": "starterGrams",
        "type": "number",
        "default": 100,
        "min": 0,
        "max": 100000,
        "step": 5
      },
      {
        "name": "starterHydration",
        "type": "number",
        "default": 100,
        "min": 50,
        "max": 150,
        "step": 5,
        "slider": true
      }
    ],
    "outputs": [
      {
        "name": "trueHydration",
        "precision": 1,
        "unit": "%",
        "optional": true
      },
      {
        "name": "totalFlour",
        "precision": 1,
        "unit": "g"
      },
      {
        "name": "totalWater",
        "precision": 1,
        "unit": "g"
      },
      {
        "name": "doughWeight",
        "precision": 0,
        "unit": "g"
      }
    ],
    "interpret": null
  }
}
