{
  "id": "ph",
  "version": "6ccffaa67b72",
  "status": "published",
  "name": "pH Calculator",
  "question": "What is the pH?",
  "summary": "Finds pH, pOH, the hydronium ion concentration [H₃O⁺] and the hydroxide ion concentration [OH⁻] of a water solution at 25 °C from any one of them, and says whether it is acidic, neutral or basic.",
  "category": "chemistry",
  "subcategory": "solutions",
  "url": "https://www.acalculator.org/chemistry/ph-calculator",
  "markdown": "https://www.acalculator.org/chemistry/ph-calculator.md",
  "kind": "formulas",
  "method": "pH = −log₁₀[H₃O⁺]; pOH = −log₁₀[OH⁻]; pH + pOH = 14.00 at 25 °C, so [H₃O⁺] = 10^−pH and [OH⁻] = 10^−pOH.",
  "assumptions": [
    "A water solution at 25 °C, where Kw = [H₃O⁺][OH⁻] = 1.0 × 10⁻¹⁴ and pH + pOH = 14.00.",
    "Concentrations stand in for activities, as in introductory chemistry; very strong solutions differ.",
    "pH and pOH from −2 to 16; concentrations from 10⁻¹⁶ to 100 mol/L."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "ph": {
        "title": "pH",
        "description": "The pH: −log of the hydronium ion concentration.",
        "type": "number",
        "minimum": -2,
        "maximum": 16
      },
      "poh": {
        "title": "pOH",
        "description": "The pOH: −log of the hydroxide ion concentration.",
        "type": "number",
        "minimum": -2,
        "maximum": 16
      },
      "h": {
        "title": "[H₃O⁺] (mol/L)",
        "description": "The hydronium (hydrogen) ion concentration in moles per liter, such as 1.2e-3.",
        "type": "number",
        "minimum": 1e-16,
        "maximum": 100
      },
      "oh": {
        "title": "[OH⁻] (mol/L)",
        "description": "The hydroxide ion concentration in moles per liter, such as 0.0125.",
        "type": "number",
        "minimum": 1e-16,
        "maximum": 100
      }
    }
  },
  "solve": {
    "fillAny": 1,
    "variables": [
      "ph",
      "poh",
      "h",
      "oh"
    ],
    "inputsOnly": []
  },
  "outputs": {
    "pH": {
      "label": "pH",
      "description": "The pH: −log of the hydronium ion concentration.",
      "format": "number"
    },
    "pOH": {
      "label": "pOH",
      "description": "14.00 − pH at 25 °C.",
      "format": "number"
    },
    "h": {
      "label": "[H₃O⁺] (mol/L)",
      "description": "10^−pH moles per liter.",
      "format": "number"
    },
    "oh": {
      "label": "[OH⁻] (mol/L)",
      "description": "10^−pOH moles per liter.",
      "format": "number"
    },
    "nature": {
      "label": "The solution is",
      "description": "Acidic below pH 7, neutral at pH 7, basic (alkaline) above pH 7, at 25 °C.",
      "format": "text"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "h": 0.0012
    },
    "outputs": {
      "pH": 2.9208187539523753,
      "pOH": 11.079181246047625,
      "oh": 8.333333333333327e-12,
      "nature": "acidic"
    },
    "text": "The pH is 2.92: the solution is acidic."
  },
  "examples": [
    {
      "given": {
        "h": 0.0012
      },
      "expect": {
        "ph": 2.9208187539523753,
        "poh": 11.079181246047625,
        "nature": "acidic"
      },
      "source": "OpenStax, Chemistry 2e, §14.2 pH and pOH (pH = −log[H₃O⁺], pOH = −log[OH⁻], pH + pOH = 14.00 at 25 °C; Example 14.4: [H₃O⁺] = 1.2 × 10⁻³ M gives pH 2.92; Example 14.5: pH 7.3 gives 5 × 10⁻⁸ M; Example 14.6: 0.0125 M KOH gives pOH 1.903 and pH 12.10), https://openstax.org/books/chemistry-2e/pages/14-2-ph-and-poh (retrieved 2026-10-02); Python 3: -math.log10(1.2e-3)"
    },
    {
      "given": {
        "ph": 7.3
      },
      "expect": {
        "h": 5.011872336272725e-8,
        "poh": 6.7,
        "nature": "basic"
      },
      "source": "OpenStax, Chemistry 2e, §14.2 pH and pOH (pH = −log[H₃O⁺], pOH = −log[OH⁻], pH + pOH = 14.00 at 25 °C; Example 14.4: [H₃O⁺] = 1.2 × 10⁻³ M gives pH 2.92; Example 14.5: pH 7.3 gives 5 × 10⁻⁸ M; Example 14.6: 0.0125 M KOH gives pOH 1.903 and pH 12.10), https://openstax.org/books/chemistry-2e/pages/14-2-ph-and-poh (retrieved 2026-10-02) (5 × 10⁻⁸ M to one figure); Python 3: 10**-7.3",
      "tolerance": 1e-12
    },
    {
      "given": {
        "oh": 0.0125
      },
      "expect": {
        "poh": 1.9030899869919435,
        "ph": 12.096910013008056,
        "nature": "basic"
      },
      "source": "OpenStax, Chemistry 2e, §14.2 pH and pOH (pH = −log[H₃O⁺], pOH = −log[OH⁻], pH + pOH = 14.00 at 25 °C; Example 14.4: [H₃O⁺] = 1.2 × 10⁻³ M gives pH 2.92; Example 14.5: pH 7.3 gives 5 × 10⁻⁸ M; Example 14.6: 0.0125 M KOH gives pOH 1.903 and pH 12.10), https://openstax.org/books/chemistry-2e/pages/14-2-ph-and-poh (retrieved 2026-10-02); Python 3: -math.log10(0.0125), 14 - that",
      "tolerance": 1e-12
    },
    {
      "given": {
        "h": 1e-7
      },
      "expect": {
        "ph": 7,
        "poh": 7,
        "oh": 1e-7,
        "nature": "neutral"
      },
      "source": "hand calculation in content.mdx: −log(10⁻⁷) = 7, and 14 − 7 = 7; OpenStax, Chemistry 2e, §14.2 pH and pOH (pH = −log[H₃O⁺], pOH = −log[OH⁻], pH + pOH = 14.00 at 25 °C; Example 14.4: [H₃O⁺] = 1.2 × 10⁻³ M gives pH 2.92; Example 14.5: pH 7.3 gives 5 × 10⁻⁸ M; Example 14.6: 0.0125 M KOH gives pOH 1.903 and pH 12.10), https://openstax.org/books/chemistry-2e/pages/14-2-ph-and-poh (retrieved 2026-10-02)",
      "tolerance": 1e-12
    }
  ],
  "sources": [
    "OpenStax, Chemistry 2e, §14.2 pH and pOH (pH = −log[H₃O⁺], pOH = −log[OH⁻], pH + pOH = 14.00 at 25 °C; Example 14.4: [H₃O⁺] = 1.2 × 10⁻³ M gives pH 2.92; Example 14.5: pH 7.3 gives 5 × 10⁻⁸ M; Example 14.6: 0.0125 M KOH gives pOH 1.903 and pH 12.10). https://openstax.org/books/chemistry-2e/pages/14-2-ph-and-poh (retrieved 2026-10-02)"
  ],
  "related": [
    "molarity",
    "concentration",
    "dilution"
  ],
  "changelog": []
}
