It's a complex issue. I think there's a lot of reasons dogs wind up too fat, and while some of them can be addressed by education, it's a really delicate topic for a lot of human reasons and can be really difficult to communicate with people in a way that's effective, kind, and doesn't make the owners defensive or resistant. I, personally, have decided to keep my mouth shut unless it's either a dog owned by someone I know very well and have a good relationship with, or someone actively asks for advice/opinions.
Reasons dogs might be obese:
This can be anything from not knowing a 'cup' on the feeding recommendations refers to a specific unit of measurement, not any random cup-like object, to not realizing that some dogs will not self-regulate if free fed, to not knowing what a healthy weight looks like on their dog, to not realizing that feeding guides aren't hard and fast rules and their dog might need less than the recommended amount. I do think this can be helped by education, though sometimes generic advice can cause more confusion. I've seen lots of people who think their dog is a healthy weight because "they have a tuck", when the dog has a very deep-chested, thin-waisted build and would have to look like a watermelon before it lost the tuck. Conversely, you see people who have barrel-chested breeds with very little tuck, like labs, who think their dogs are fine because it's hard to evaluate how much fat they're carrying by looks alone, and they don't know how to evaluate it by touch. Or because they believe myths like labs needing a fat layer because they're bred to retrieve in cold water.
- Medical issues
Thyroid problems, pathological appetite issues, medications that cause metabolism/appetite changes... sometimes there's a limit to what people can do in these situations, and sometimes the dog is being treated and just hasn't recovered yet, and sometimes the owner doesn't realize unusual weight changes can be caused by treatable medical conditions. This is definitely one situation that makes me very reluctant to comment on strangers' dogs' weight - online or otherwise - because owners of these dogs hear about it all the time and most are literally doing everything they can to manage it. There's also the rare case of dogs with chronic conditions that cause weight loss when they flair up, and sometimes these dogs are kept a little heavier in an attempt to keep them from getting dangerously skinny.
- Recent rehome
The dog came from a home or shelter/rescue situation where their weight got out of hand, and the new owner is working on it but healthy, safe weight loss takes time. Similar to medical issues, it can be really frustrating to these owners to hear that their dog is fat all the time when they really are on the road to getting healthier.
- Human error
When you see the same dog every day, sometimes you just don't notice the weight creeping up. Maybe something has happened like the owner's started a new job so the dog doesn't get as much exercise, or the weather's turned nasty for a bit, or a pandemic happens, but suddenly they look at their dog one day and go "oh, crud, they're fat". This is especially true with small dogs, where a pound or two can make a big difference, but when there's a major thing going on at home even larger dogs can plump up before anyone realizes what's going on. True, usually you don't see dogs reach obese in these scenarios, but we are only human and sometimes these things get away from us.
- Human illness
These cases are sometimes very dramatic (look up Obie the Dachshund if you're not already familiar), but also very tragic. Dementia and other illnesses can cause owners to literally not remember that they've already fed their dogs, and to be unable to process that the animal has changed weight considerably. This can even be a problem in a household where there are other adults acting as caretakers, as it can be very difficult to prevent the ill person from overfeeding or feeding inappropriate foods to the pets in some situations. In less extreme cases, you also have people who are contending with chronic or long-term diseases or difficult treatments (depression, cancer, chronic pain conditions, etc.) and sometimes they're doing the best they can but the dog's weight gets away from them, and they have so many other things on their plate that it just doesn't get prioritized the way it would under ideal circumstances.
- The 'look'
I honestly think it's pretty darn rare to have people deliberately 'fatten up' their animals, but there is a cultural thing right now with fat animals being cute. However, I more often see this with people who have 'tough' breeds and want to boast about how bulky their 200lb Rottweiler is - all muscle, of course! - when really they've just made their dog obese. Either way, this is a pretty hard subset of people to influence, because the clout is more important to them than the animal. Thankfully it's also a pretty darn small percentage of dog owners.
And then you have the issue of communication. Of course dogs don't have to deal with social shaming, body image problems, eating disorders, etc., but we can't ignore that the humans taking care of them do. And there are the people who conflate food with love, and may find it extremely emotionally difficult to reduce treats or food. Some feel that the dog won't love them anymore, which can be hard on them when the dog is literally their only companion or has some other significant emotional significance in their life. While there are people who might respond to a very direct, hard-ass "your dog is fat and if you don't fix it you'll kill them" approach, many more people are going to feel attacked and alienated. They do love their animals, after all. Kindness and understanding for where they're coming from will go a lot farther in making the message actually stick.