Abstract : We derive an expression that allows for the unambiguous evaluation of the overlap between two arbitrary quasiparticle vacua, including its sign. Our expression is based on the Pfaffian of a skew-symmetric matrix, extending the overlap formula recently proposed by Robledo [ Phys. Rev. C 79 021302 (2009)] to the most general case of quasiparticle vacua, including the one of the overlap between two different blocked n-quasiparticle states for either even or odd systems. The powerfulness of the method is illustrated for a few typical matrix elements that appear in realistic angular-momentum-restored generator coordinate method calculations when breaking time-reversal invariance and using the full model space of occupied single-particle states.