Please don't die from this advice.
First: Yes, best before dates are sometimes arbitrary depending on the product and where you live.
However, basically anything with a package sold commercially has been tested for taste/feel/look over time to determine when quality degrades.
If you make cookies you don't want people only buying up 1+ yr old boxes and thinking your cookies are just supposed to taste like solidified disks of keyboard powder. Having a best before date tells people when your product tastes as intended and when it's only worth buying from the discount bin.
It's fair to say sometimes marketing bullshit influences that date.
Second: Expiry dates are a real thing, at least where I'm from. Fridge/freezer temperatures are meant to be within specific ranges and there are food safety regulations around how long certains items can be outside of those ranges - like for transport or during prep.
Expiry dates are based on testing the development of bacteria colonies/degradation of the ingredients in an average of settings one would expect those products to go through.
Just because something says it's expired doesn't necessarily mean it's unsafe, though. Except: in a commercial kitchen it is illegal to sell expired ingredients because of the testing that goes into determining that date.
I've worked as a chef, have taken multiple food safety courses, had good relationships with food inspectors. And I've worked in a production kitchen where the products were sent to testing facilities for determining the dates we put on the labels.