Accurate biological models are critical to reliably predict vulnerability of marine organisms and ecosystems to rapid environmental changes. Current predictions on the biological impacts of climate change and human-caused disturbances primarily stem from controlled experiments but lack assessments of the mechanisms underlying biotic variations in natural systems. Such information is key to translating experimental models to natural populations, especially for habitat-forming, climate sensitive species with key ecological roles. This study aimed to characterize and quantify spatial patterns of shell biomineralization and biomechanical properties in a key reef-building oyster,Crassostrea virginica, collected from restored reefs along natural estuarine gradients in the Hudson River Estuary (NY, U.S.). We characterized patterns of oyster shell production (i.e., shape and thickness), structure (i.e., abundance of foliated and chalky calcite), mineralogy (i.e., crystal size and density), composition (i.e., organic matrix and Mg/Ca ratios), and mechanical performance (i.e., elastic modulus and hardness) at the macro and micro scale. Our results demonstrate a strong protective capacity ofC. virginicafor compensatory adjustments in shell biomineralization and biomechanics to maintain shell production and protective functions as a response to biotic and abiotic stressors. We reveal salinity as a key predictor of oyster shell structure, mechanical integrity, and resistance to dissolution, and describe the functional role of chalky calcite in shaping shell mechanical performance. Compensatory adjustments along salinity gradients indicate that oysters produce shells withi) high mechanical resistance but increased vulnerability to dissolution under marine conditions, andii) lower structural integrity but higher protection from dissolution under brackish conditions. Our work illustrates that biomineralization and biomechanical adjustments may act as compensatory mechanisms in eastern oysters to maintain overall performance under heterogeneous estuarine environments, and could represent a cornerstone for calcifying organisms to acclimate and maintain their ecological functions in a rapidly changing climate.