It depends on what you mean by quality birds.
If you're talking dependable layers or decent meat birds, then a hatchery will give you that.
If you're talking exhibition quality or quality aligning with the standard for the breed, breeders for sure. Even national hatcheries that claim they have heritage or exhibition lines are still breeding those lines to fill many, many orders. That means less focus is put on each individual bird in the breeding flock and more on producing chicks out of them to sell, so birds of lesser quality remain in the gene pool because they need so many eggs to put in the incubator each week. Some breeders get like this as well, pumping out chicks to make money rather than for the passion of breeding quality birds and producing more quality birds, so you do need to do your research before settling on buying from a breeder just because they're a breeder rather than a hatchery. But if you can find a breeder of your chosen breed that really knows their stuff and has that passion for their breed, they and their birds are worth their weight in gold. And if you can find them locally, all the better!