The occurrence of wellbore mechanical failure is a consequence of the interaction among factors such as in situ stress, rock strength, and engineering procedures. The process of hydrocarbons production, causing reduction of pore pressure, alters the effective stresses in the vicinity of a borehole, leading to borehole instability issues. Estimating the rocks’ elastic modulus and compressive strength is essential to comprehend the rock matrix’s mechanical response during drilling and production operations. This study aimed to assess the practicality of Diammonium Hydrogen Phosphate (DAP) application as a chemical for strengthening chalk in hydrocarbon reservoirs, to make it resistant to high stresses and failure during drilling and production. The mechanical and physical properties of Austin chalk rock samples treated with DAP under mimicked reservoir conditions were studied. The results showed that DAP is a highly effective carbonate rock consolidating agent that improves the mechanical strength of the chalk. Compressive test measurements conducted on rocks treated at two different temperatures (ambient and 50 °C) showed that DAP effectively strengthened the rock matrix, resulting in an increase in its compressive strength (22–24%) and elastic modulus (up to 115%) compared to the untreated sample. The favorable outcomes of this research suggest that the DAP solution holds promise as a consolidation agent in hydrocarbon reservoirs. This contributes to the advancement of knowledge regarding effective strategies for mitigating mechanical failures of the wellbore during drilling and production.