For years people have focused on worrying about what do to do when the dog has an accident. There was the rolled up newspaper swat, pushing the dog’s nose in it, shaking the dog by the scruff of his neck, and the list goes on. These methods, aside from being inhumane, fail to communicate what you want. The dog understands that it’s his mess, but he doesn’t understand why you’re angry about it.
Instead, focus on celebrating your dog’s successes, so your pooch understands what he’s done right. Take your dog on a leash to the same place to do his business. When he succeeds, let the celebrations begin. Immediately give him a treat (an incredibly special and tasty morsel used only for this purpose), praise (you now become an actor; if you want this housetraining to work, you need to enthusiastically cheer, "Good boy, Max!" like you mean it), and then play with your dog. If you’re in a hurry, don’t worry – even a 60-second play session is fine. If you want to play longer, that’s also fine.
However, if, after 10 or 15 minutes, your pooch refuses to do his business, just calmly take him back indoors. Tether his leash to your belt, so he can’t sneak off behind the sofa to make a mess. Except that he’s tethered to you, totally ignore him for a good 15 minutes, then take him back outside and try again.
The more successes you have, the more your dog will understand what you want and will realize that if he does his business in this outdoor spot, good things happen.
The reality is that all puppies have accidents, though, no matter what you do. (When dogs have repeated accidents, see your veterinarian to rule out a urinary tract infection or another medical cause.) Of course, clean up any mess using an odor neutralizer. However tempting, don’t reduce yourself to the antiquated approach of punishing your dog. Just increase your vigilance, and make sure you praise your dog every single time he gets it right. This method not only works for puppies, but also for adopted shelter and rescue dogs who may need a refresher course in housetraining.