Alkaline

In oil and gas operations, alkaline describes any aqueous solution or solid material with a pH greater than 7.0, meaning the molar concentration of hydroxide ions [OH-] exceeds the molar concentration of hydrogen ions [H+] at 25°C, where pH = -log[H+]. At neutral pH 7.0, [OH-] = [H+] = 1.0 × 10-7 mol/L; at pH 9.0, [OH-] = 1.0 × 10-5 mol/L while [H+] = 1.0 × 10-9 mol/L, a 100-fold difference. The term alkaline is used interchangeably with "basic" in oilfield chemistry and applies to four principal contexts: drilling fluid (mud) pH control, where maintaining alkaline conditions in the range pH 8.5 to 12.5 depending on mud type protects steel equipment from corrosion, inhibits reactive shale hydration, stabilises organic fluid additives, and prevents hydrogen sulfide (H2S) evolution from sulfide-bearing formations; wellbore cement chemistry, where the highly alkaline pore water of hydrated Portland cement (pH 12.5 to 13.5) provides passive corrosion protection to the carbon steel casing inside the cement sheath through formation of a stable iron oxide passive film; formation water geochemistry, where naturally alkaline formation waters (pH 7.5 to 9.0) derived from carbonate reservoirs in the Western Canada Sedimentary Basin (Cardium, Viking, Mannville) contain dissolved bicarbonate (HCO3-) and carbonate (CO32-) alkalinity that affects scale precipitation and injection water compatibility; and enhanced oil recovery, where alkaline flooding injects NaOH, Na2CO3, or Na2SiO3 solutions at pH 10 to 13 to react with crude oil organic acids and reduce interfacial tension. Measurement and control of alkalinity in drilling fluids is performed daily at the well site using the standardised titration tests specified in API Recommended Practice 13B-1 (Water-Based Drilling Fluids), and the results guide the addition of caustic soda (NaOH), hydrated lime (Ca(OH)2), potassium hydroxide (KOH), or magnesium oxide (MgO) to maintain target pH ranges.

Key Takeaways

  • API RP 13B-1 defines three standard alkalinity titration tests for water-based drilling fluids — Pf (filtrate phenolphthalein alkalinity), Pm (whole-mud phenolphthalein alkalinity), and Mf (filtrate methyl orange alkalinity) — and the ratios among these three values diagnose the specific OH-, CO32-, and HCO3- ion balance in the mud system: The Pf test titrates the filtered mud filtrate with 0.02 N H2SO4 to the phenolphthalein endpoint (pH 8.3, colour change from pink to colourless), measuring the combined concentration of OH- and CO32- alkalinity in mL of titrant per mL of filtrate. The Pm test performs the same titration on the whole mud sample, accounting for alkaline solids (Ca(OH)2 particles in lime muds, MgO in carbonate-resistant muds) suspended in the mud that are not present in the filtrate. The Mf test titrates the filtrate with 0.02 N H2SO4 to the methyl orange endpoint (pH 4.3), which captures the additional bicarbonate (HCO3-) alkalinity not measured by phenolphthalein. Using these three values, the mud engineer can diagnose the carbonate status: if Pf > 0 and Mf = 0, the filtrate contains only OH- (no carbonate contamination); if Pf > 0 and Mf > 0, carbonate (CO32-) and/or bicarbonate (HCO3-) contamination is present, indicating CO2 influx from shallow gas or cement contamination; if Pf = 0 and Mf > 0, the filtrate is below pH 8.3 and is dominated by bicarbonate without sufficient OH- to maintain alkaline conditions, a serious contamination state requiring immediate caustic treatment. For a fresh water bentonite mud targeting pH 9.0 to 9.5, the expected values are Pf = 1.0 to 2.5 mL/mL, Pm = 2 to 5 mL/mL, Mf = 0, with any deviation from Mf = 0 indicating carbonate contamination that must be investigated and treated.
  • Target pH ranges differ significantly between mud types because the chemical environment required for optimal performance of each mud system's primary weighting and filtration-control additives differs, and operating outside the target range degrades mud performance through additive breakdown, emulsion destabilisation, or corrosive attack on drill string and formation: Fresh-water bentonite muds operate at pH 8.5 to 9.5: below pH 8.5, bentonite platelets aggregate (flocculation), increasing viscosity uncontrollably and reducing filtration control; above pH 9.5 in the presence of calcium ions from cement or formation contamination, calcium hydroxide precipitates and can cause excessive gelation. Gyp (gypsum) muds are designed to tolerate 800 to 1,800 mg/L calcium and operate at pH 9.5 to 10.5 maintained with NaOH, which keeps lime (Ca(OH)2) at the solubility limit and prevents carboxymethylcellulose (CMC) filtration-control additives from flocculating. Lime muds (used in highly reactive shale sections of the Alberta Foothills and Deep Basin) operate at pH 11.5 to 12.5, maintained by excess Ca(OH)2 solids at 3 to 8 kg/m³ in the mud, which buffers pH at the lime solubility limit of 12.4 and provides sustained alkalinity even when the mud is contaminated by CO2 or bicarbonate formation water. KCl/polymer muds (used in salt-sensitive Montney, Duvernay, and Devonian formations) target pH 9.0 to 10.0 to maintain KOH-stabilised conditions without the high calcium levels that would cause polymer degradation. Maintaining each mud type within its target pH range is a daily operational requirement checked against the API RP 13B-1 titration results and adjusted by adding the appropriate alkalinity source (NaOH for incremental increase, Ca(OH)2 for buffered lime-mud maintenance, soda ash for calcium reduction combined with pH adjustment).
  • Portlandite (Ca(OH)2), the primary alkaline phase produced during Portland cement hydration, buffers the cement pore water to pH 12.5 to 13.5 and provides passive corrosion protection to the encased carbon steel casing through formation of a stable magnetite (Fe3O4) and iron oxide passive film on the steel surface, but CO2 ingress (carbonation) progressively neutralises portlandite and reduces the pH to below 9.5, destroying the passive film and initiating active corrosion: Portland cement hydration produces approximately 20 to 25 wt% portlandite (Ca(OH)2) by mass of cement, along with calcium silicate hydrate (C-S-H) gel, ettringite, and other hydration phases. Portlandite dissolves slowly into the cement pore water, maintaining pH at 12.5 to 13.5 as long as intact portlandite reserves remain in the cement matrix. At this pH, the steel surface maintains a tightly adherent passive oxide film that limits active corrosion rates to below 1 micrometre per year, equivalent to less than 0.1 mm casing wall loss per century. When CO2 (from geothermal gas in the annulus or from carbonic acid formation water in the cement-formation contact zone) reaches the cement, it reacts with portlandite: Ca(OH)2 + CO2 → CaCO3 + H2O, consuming alkalinity and reducing pH. When portlandite is fully consumed, the remaining C-S-H gel buffers pH at 10 to 12; if decalcification continues, pH falls below 9.5 and the passive film on the embedded casing becomes unstable, allowing active corrosion at rates of 0.1 to 2 mm/year in CO2-wet environments. This carbonation-driven corrosion mechanism is a significant casing integrity concern in sour or CO2-containing wells in the WCSB, particularly in the Wabamun Lake area where shallow CO2-bearing formations contact the cemented casing annulus at depths of 300 to 800 m.
  • Formation water bicarbonate alkalinity in WCSB carbonate and sandstone reservoirs is a significant water quality variable that controls scale precipitation tendency, injection water compatibility, and the efficiency of alkaline EOR flooding: Formation waters in Cardium (Upper Cretaceous), Viking (Lower Cretaceous), and Mannville (Lower Cretaceous) sandstone reservoirs in Alberta typically contain 200 to 1,200 mg/L total alkalinity expressed as mg CaCO3/L, with the alkalinity predominantly as bicarbonate (HCO3-) at pH 7.0 to 8.0. When these formation waters are produced to surface and commingled with injection water at different bicarbonate and calcium concentrations, calcium carbonate (CaCO3) scale may precipitate if the ion product [Ca2+][CO32-] exceeds the solubility product Ksp = 3.36 × 10-9 at 25°C. The Langelier Saturation Index (LSI = pHmeasured - pHsaturation) quantifies this tendency: LSI > 0 indicates CaCO3 scale-forming conditions; LSI < 0 indicates undersaturated (non-scaling) conditions. Alberta waterflood injection water compatibility assessments routinely calculate LSI for blended produced and freshwater injection streams before scaling the waterflood programme. For Pembina Cardium waterflood operations (the world's largest waterflood by injection volume at peak rates of 200,000 to 300,000 bbl/day), bicarbonate alkalinity compatibility between produced water (300-600 mg CaCO3/L) and shallow aquifer injection water (100-200 mg CaCO3/L) requires continuous scale inhibitor injection at 5 to 20 ppm to prevent tubing and perforations plugging by CaCO3 deposition.
  • The distinction between true pH (measured with a calibrated electrode at reservoir temperature) and surface-measured pH (at laboratory temperature) is significant in deep WCSB wells where temperature effects on the dissociation equilibria of CO2, H2CO3, HCO3-, and CO32- shift the effective alkalinity of the mud filtrate and formation water by 0.3 to 0.8 pH units relative to the surface measurement: The dissociation constants for carbonate species are temperature-dependent: K1 (H2CO3 dissociation, pK1 = 6.35 at 25°C) increases with temperature (pK1 = 6.12 at 60°C), meaning that at higher temperatures a smaller fraction of total dissolved carbon dioxide remains as H2CO3 and more dissociates to HCO3-, shifting the apparent pH measurement. The autoionisation of water (KW) also changes with temperature: at 25°C, neutral pH = 7.00; at 80°C, neutral pH = 6.40. This means a formation water or mud filtrate measured at pH 8.5 on the surface (well above the 25°C neutral point of 7.0) is only marginally above the 80°C neutral point of 6.4 and may not provide the expected corrosion protection level at formation conditions. Downhole pH measurement using permanently installed pH-sensing fibre optic systems (deployed in about 2% of Canadian SAGD wells by 2024) provides real-time in-situ pH data that is significantly more accurate for corrosion rate modelling and scale prediction than surface measurements corrected with empirical temperature adjustments. For Athabasca SAGD wells where steam temperatures of 200 to 240°C are injected, the pH of the condensate phase at steam temperature can be 4 to 5 pH units lower than the surface measurement of the same water after cooling, a difference large enough to change the corrosion rate prediction for the injection wellbore by an order of magnitude.

pH Control Chemistry in Water-Based Drilling Fluids

The primary alkalinity sources used in water-based drilling fluid systems are sodium hydroxide (NaOH, caustic soda), hydrated lime (Ca(OH)2), potassium hydroxide (KOH), and magnesium oxide (MgO). NaOH is a strong base that dissociates completely in water: NaOH → Na+ + OH-. A single kg of NaOH added to 1 m³ of mud filtrate raises pH from 8.5 to approximately 9.8 (starting from pH 8.5), with the exact increment depending on the existing buffering capacity of the mud system. Ca(OH)2 is a sparingly soluble weak base with a solubility of approximately 1.5 g/L at 25°C (declining to 0.8 g/L at 80°C), which buffers mud pH at approximately 12.4 as long as undissolved lime particles remain in the system — an important self-regulating property for lime muds drilling through highly reactive shale where CO2 influx intermittently consumes alkalinity. KOH is used in salt-tolerant and potassium chloride (KCl) muds where sodium ions must be minimised to avoid clay dispersion, providing the same OH- per mole as NaOH but at higher cost (approximately 3 to 4× the cost per kg of NaOH at 2024 Alberta industrial chemical prices).