Loss of appetite is a non-specific symptom. It can be caused by anything from a temporary stomach upset and stress to dental problems, pain, fever or disease in an internal organ. It is therefore more useful to assess your dog's behaviour as a whole than just to count missed meals.
Look at energy levels, thirst and whether your dog has vomiting, diarrhoea, coughing, pain or other changes. A dog that sniffs at its food but seems to want to eat may have a different problem from a dog that has no interest at all. If the loss of appetite continues, the vet may need to examine the mouth, the abdomen and the other organ systems and add tests if needed.
Contact a vet if your dog stops eating completely, becomes clearly tired or develops other symptoms. Puppies, very small dogs, older dogs and dogs with a known illness may need to be seen sooner, because their margins can be smaller.