While there is no guaranteed way to prevent cancer in dogs, some steps can be taken to reduce their risk. These include maintaining a healthy diet and weight, regular exercise, avoiding exposure to known carcinogens (such as tobacco smoke), and ensuring your dog receives regular veterinary check-ups to detect any early signs of cancer.