Maggots on dogs is also known as myiasis. Maggots that infest your dog are actually flies still in their larvae state. Most of the time, maggots infest dogs that need medical attention for a different issue (overexposure to the outdoors, skin infection, draining wound or urine/fecal matter on dog's coat). Once the dog is properly cared for, the maggots will no longer be an issue. However, the first thing you need to do is kill the maggots.
Take your dog to the veterinarian. This should always be your first step when you suspect your dog has a maggot infestation. Follow your veterinarian's advice.
Locate the maggots on your dog. The maggots will be on a part of the dog's coat that is moist, infected, wounded, covered in urine/fecal matter or otherwise decaying.
Use an electric razor on the lowest setting to shave the fur where the maggots are located. This will allow you to see the maggot infestation more fully.
Remove the maggots from your dog's skin one at a time. Since there can be dozens or hundreds of maggots, you might be doing this for several hours. Place the maggots in a bucket as you remove them. Tweezers can help you get maggots that have burrowed under the skin.
Spread a mild insecticide on your dog's skin. Leave it on for just a minute or two and then rinse thoroughly. This will make sure there are no other live maggots and help prevent the infestation from reoccurring.
Take the bucket of maggots away from your dog. Then, pour the insecticide over the maggots to kill them.
Bring your dog back to the veterinarian for another examination. The underlying cause may need more attention or an infection might develop.
Keep your dog indoors most of the day. Brief periods outside under your supervision or walks should be all the time your dog spends outdoors. Prevent future maggot infestations by making sure your dog is clean and that any skin problems are dealt with by a veterinarian immediately.