Unproven doesn’t mean ineffective. Cranberry juice isn’t FDA approved to help with urinary tract infections, but is frequently recommended by urologists and works. Another example is that isopropyl alcohol, which is an effective disinfectant, doesn’t meet the EPA standards for being a pesticide… which is because it’s existence predates the process.
It’s expensive to go through that rigorous process, and there’s no economic incentive to go through that for something that isn’t patentable. In the case of cranberry juice, it’s not sold as medicine. In the case of alcohol, you can buy very expensive wipes that have a certification if you need it for some industrial process.
Funnily enough, cranberry juice does not show any clinical benefit for treating UTIs over and above simple hydration, and it shows minimal benefit for UTI prevention.
That really doesn't mean shit since it anecdotally works to all the folks that have had UTIs. Whether the causal effect is indirect is really asides the point. It works.
Anecdata aren’t data, and via experimental results, cranberry juice does not work. It’s often recommended, but it has the same scientific basis as drinking 8 glasses of water or walking 10,000 steps. Which is to say, it’s a marketing ploy.
Cranberry juice is no more effective on UTIs than chicken soup on colds and flus. That is, it can have an impact in part because of the placebo effect (which is substantially more powerful than is currently understood), but it is not because there is any inherent benefit to cranberry juice ("chicken soup" — that is, any clear broth — is at least partially effective because it’s warm liquid fighting diseases which cause dehydration; there’s no medicinal benefit).