Let G be one of the Artin groups of finite type B n = C n and affine type $${\tilde{\mathbf {A}}_{n-1}}$$ , $${\tilde{\mathbf {C}}_{n-1}}$$ . In this paper, we show that if α and β are elements of G such that α k = β k for some nonzero integer k, then α and β are conjugate in G. For the Artin group of type A n , this was recently proved by González-Meneses. In fact, we prove a stronger theorem, from which the above result follows easily by using descriptions of those Artin groups as subgroups of the braid group on n + 1 strands. Let P be a subset of {1, . . . , n}. An n-braid is said to be P-pure if its induced permutation fixes each $${i\in P}$$ , and P-straight if it is P-pure and it becomes trivial when we delete all the ith strands for $${i\not\in P}$$ . Exploiting the Nielsen–Thurston classification of braids, we show that if α and β are P-pure n-braids such that α k = β k for some nonzero integer k, then there exists a P-straight n-braid γ with β = γαγ −1. Moreover, if $${1\in P}$$ , the conjugating element γ can be chosen to have the first strand algebraically unlinked with the other strands. Especially in case of P = {1, . . . , n}, our result implies the uniqueness of roots of pure braids, which was known by Bardakov and by Kim and Rolfsen.