Specifically it can be legal in the United States, where commercial speech (speech made in order to elicit business transactions) is not as strongly protected as political speech (speech containing ideas and beliefs). As a general rule, you must advertise your product truthfully, but that offers a lot of wiggle room that as "exact truth" is perfectly fine as is boastful and outlandish statements.
For example, lets start with one of the most fun ad campaigns the old "9 out of 10" experts slogans. These are true, but often the methodology is misleading. While you expect 90% of all experts would say the same thing, often the survey will do numerous panels until they find one of the exact ratio... and that's if they are being semi-honest. Most will just take the first 9 experts who agree with them and one of the many more who don't agree and boom, here's your panel. And then the question might be overly narrow. The first advert campaign to use this was for Trident gum and specifically asked 10 doctors "Which gum would dentists recommend to patients who want to chew gum? 9 out of 10 say Trident!" Note the bolded phrase. None of the dentists they found would recommend chewing gum... but if you're going to do it anyway, chew Trident (the tenth doctor actually answered that he wouldn't recommend patients chew gum at all... which technically is true in that he's not recommending Trident... but he's not recommending Bubble Yum either.).
In food ads, you have to use the actual food product in your ad, not a fake. But you can apply all manner of toxic chemicals to the cooked Big Mac to make it look like the most perfect burger ever made, a feast fit for the gods, rather than the typical greasy mess of meat and condiments slapped in a sesame seed bun. So long as that is a Big Mac at the core of the plastic coating making it look oh so tempting. Happens in just about every food commercial.
Perhaps the most interesting treatment of the product that goes straight to your question is the homeotherapy product known as Head On, which the public will tell you is used to cure headaches... but the product will never say that (largely because per U.S. law, you can't advertise a product as a cure for a medical ailment unless the FDA specifically clears the products use for treating that specific ailment.). Head On's advertisement was an annoyingly repeated list of instructions of how to use the product: "Head On, apply directly to the forehead. Head On, apply directly to the forehead (repeats some more)." This is all true, as the instructions for the product's use are stated correctly... it's just that they don't say what will happen when you apply it directly to the forehead, letting the viewer assume that it cures headaches... instead of saying that legally speaking, the FDA only clears them to say it legally cures you of the amount of change in your wallet that they will sell a stick of Head On to you in the store (i.e. bupkis). The headache relief may be related to the application of the product... or the distress of doing that motion to your head... or the placebo effect of thinking it will help somehow... or the fact that mild headaches do pass over time... or the fact that you put your boot through the TV when their annoying advert came on...