We compute perturbative corrections to matching coefficients of QCD to HQET for the matrix element of the ΔB=2 operator that determines the mass difference in B0−Bˉ0 system of states. This involves the technical point of choosing the operator basis in HQET, separating physical operators from evanescent ones. We obtain an analytical result for some of the two-loop corrections at order αs2.