We prove generalized Fefferman-Stein type theorems on sharp functions with Ap weights in spaces of homogeneous type with either finite or
infinite underlying measure. We then apply these results to establish mixed-norm weighted Lp-estimates for elliptic and parabolic equations/systems with
(partially) BMO coefficients in regular or irregular domains.