Molecular mechanisms underlying quantitative variations of pathogenicity remain elusive. Here, we identified the Xanthomonas campestris XopJ6 effector that triggers disease resistance in cauliflower and Arabidopsis thaliana. XopJ6 is a close homolog of the Ralstonia solanacearum PopP2 YopJ family acetyltransferase. XopJ6 is recognized by the RRS1-R/RPS4 NLR pair that integrates a WRKY decoy domain mimicking effector true targets. We identified a XopJ6 natural variant carrying a single residue substitution in XopJ6 WRKY-binding site that disrupts interaction with WRKY proteins. This mutation allows XopJ6 to evade immune perception while retaining XopJ6 virulence functions. Interestingly, xopJ6 resides in a Tn3-family transposon likely contributing to xopJ6 copy number variation (CNV). Using genetic complementation assays, we demonstrate that xopJ6 CNV allows fine-tuning of pathogen virulence on Arabidopsis through gene dosage-mediated modulation of xopJ6 expression. Together, our findings highlight how sequence and structural genetic variations restricted at a particular effector gene contribute to bacterial host adaptation.