It depends in the US and some other countries. It very important for its legality that CBD only is derived from the hemp plant to be completely legal. Marijuana-derived CBD, on the other hand, varies in legality on a state by state basis because it is still a by-product of the marijuana plant.
Good luck explaining/proving to a customs agent where your CBD was derived from-that's if he even knows what it is.