SOmetimes valid. What if you take a random sample from a population that is 100% Republican? Then your answers will not be a good representation of the whole US population, only those people from that area. So your sample has to be a good representation for a random sample to be valid.