Introduction: In the first half of 2023, a global shift was observed towards the predominance of XBB variants. China faced a significant epidemic between late 2022 and early 2023 due to Omicron subvariants BA.5.2 and BF.7. This study aims to depict the evolving variant distribution among provincial-level administrative divisions (PLADs) in China and explore the factors driving the predominance of XBB replacement.Methods: Sequences from local and imported coronavirus disease 2019 cases recorded between January 1 and June 30, 2023, were included. The study analyzed the changing distribution of viral variants and assessed how the prior dominance of specific variants, XBB subvariants, and imported cases influenced the prevalence of the XBB replacement variant.Results: A total of 56,486 sequences were obtained from local cases, and 8,669 sequences were from imported cases. Starting in April, there was a shift in the prevalence of XBB from imported to local cases, with varying dominance among PLADs. In PLADs previously high in BF.7, the rise of XBB was delayed. A positive correlation was found between XBB proportions in imported cases from January to March and local cases in April. The distribution pattern of XBB subvariants differed between local and imported cases within the same PLAD. No significant differences were noted in the replacement rates of XBB subvariants.Conclusions: The timing of XBB dominance differed among various PLADs in China in the first half of 2023, correlating closely with the prevalence of XBB variants among imported cases.