You ask for a policy on your house, they ask if a person qualified by XYZ standard approved it.
If we want to make certain protections mandatory, we can at least move the regulations up one abstraction level. Instead of "you must meet these standards", it could be something more general like, "you must have an insurance policy against these events for this much", and people go with whatever insurer is willing to take that risk. That would allow for more experimentation about which standards are good enough or too stringent, by the people who have something to lose if they're not strict enough, and provide an impetus for obsolete bits to be removed.
The role of the insurance industry is mostly a result of its having a vested interest in collecting data and mitigating risks. Keep in mind that "meeting code" is a standard for the worst legally allowed construction and hiring professionals is a market driven improvement over the provisions dealing with shoddy construction one finds in the Code of Hammurabi.
A certification program endorsed by insurance companies seems like a great idea, as does contractor-maintained liability insurance. And in a field where contractors have little to differentiate themselves except reputation and word of mouth, many specifically advertise themselves as "licensed and bonded", and people seeking a contractor look for those specifically. (Some kind of trademarked certification seems even better, to avoid any ambiguity.) All of those seem sufficient to drive contractors to voluntarily step up and seek such certification.
None of that requires mandatory licensing, though.
Now can you do electrical 'work' on residential without a permit or license? yes and sometimes it might be ignored but if the inspector(s) want to not ignore it, they can make you go by the regulations of your area.
That's an unfair characterization. Licensure is not just about protectionism, it is also about making sure that people who need to know what they're doing actually know what they're doing. And while it's far from perfect, it's pretty effective. In the U.S. it is very rare for buildings to collapse, or faulty wiring to set buildings on fire. That is in no small measure because we enforce building codes and licensure requirements for structural and electrical engineers.
And if your insurance company doesn't want to be sued so much, it makes sure you have a certification or a license or basic professional degrees of competence before insuring you.
And to make it all seem like it operates on a fair and level playing field, some independent entity has to verify that the requirements for licensing are met.
And I think we all know what that has meant, historically: multiple choice tests graded by a Scantron machine.
If a florist does something stupid - no one gets hurts.
But bankers,programmers treat their profession like the wild west.
(Of course, even licensed persons may choose to make poor choices. That said, I've taken a few of those exams, and they are no joke.)
User themselves are, too: look at all these BSD-style "provided as-is, explicitly no guarantees" licenses that people take enthusiastically.
And for something aircraft-grade or medical-grade, you definitely meet with rather strict controls on a case-by-case basis (unlike the wholesale licensing).
I think that's missing the point (at least the point in theory; the point in practice might be different). The idea is that, if you're licensed, you're sufficiently unlikely to make mistakes that an insurance company can profitably insure people like you without having to charge any individual one of you too much money. In essence, it's a way of converting the concept "People who know what they're doing are less likely to screw up" into something the market can quantify and deal with and reduce variance on.
In theory, the amount of money the building owners pay their own building insurance company is exactly equal to the chance of their building falling down times the cost of that building (plus the overhead of calculating that risk, etc.). If you want that cost to do down, the most efficient way is to convincingly lower that risk. Assuming the market is reasonably effective at transmitting information (which is a big assumption), insurance seems like a perfectly reasonable way to use the market to calculate.
Let's say you pay some people to design a building for you. You get insurance of course. A year later, the building falls down. You call your insurance company to collect. The first thing they ask is whether you took every reasonable precaution you could to prevent that from happening. Part of that would include having a licensed structural engineer design the building. If you let Joe Shmoe off the street design your building and it falls down, the insurance company is going to say you're basically SOL, because you didn't find a person you could verify was qualified.
It's really about transferring the liability from the building owner to the engineer. If there's a mistake in the design, the engineer gets sued. Guess what happens then? The engineer has professional liability insurance to pay that! How does the professional liability insurance company decide who to insure? Well, they insure people with licenses, of course. It's an elaborate scheme to transfer money from one insurance company to another.
Is it necessary for a florist? Probably not. I can't think of a situation where you'd need to sue a florist. Interior decorator might be more problematic than people realize. First, it depends on whether it's a decorator or a designer. A designer may move walls around, affecting egress paths, and can possibly have some life safety implications, so they should be able to take responsibility for that.