It is not okay to buy puppies and kittens from breeders and pet stores. There, I said it. Call me judgemental, I've been called worse, but I can't believe there are still people who refuse to adopt pets, when there are hundreds out there who need homes.
If you have room in your home for an animal, you have an opportunity to save one who nobody loves, who will die if it can't find a family. If you buy one from a breeder you're not only throwing that opportunity away, but you're also supporting an industry that breeds animals even though there are already more than we can take care of, as a society.
Pet shelters do everything they can to get pets adopted, including listening to your every wish and contacting you when the right pet comes in. I have a friend who adopted this incredible german shepherd from a shelter, and it's the coolest, happiest, most obedient dog I have ever seen. Do you want a brown dog? They'll find you one. Want a specific breed? Search for rescue foundations that focus on that breed... from border collies to really ugly hairless cats, there are hundreds of breed-specific organizations, many of which are probably in your area. A lot of these purebred animals are rescued from puppy and kitten mills, which keep baby animals in awful conditions but avoid authorities because the owners can make so much money selling to the pet stores.
I've heard hundreds of excuses and justifications from people who bought animals... they wanted a certain color or temperament or just saw it in a petstore and had to have it. The bottom line is that most of them didn't even try to look at pet adoption as an alternative, and that's really depressing. So if you have a friend who has mentioned wanting a pet, and you know they could take good care of them, please drag them to your area pet shelter and show them how to search google for "[breed] rescue in [city]". Point them towards PetFinder, where they can not only get a good idea of where to go in their city for adoptions, but spend hours looking at pictures of really, really cute puppies and kittens :)
If you need a dog for an incredibly specific purpose, like leading the blind, herding sheep, or sniffing drugs, buying one is understandable. If you just need one that's fun to pet and play fetch with, please adopt. I bought my parakeet, Naboo, about eight years ago and I never want to buy a pet from a store like that again... there are even parakeets that need homes. I just didn't know about it at the time.