I just want to add some more information about this.

First of all, even if municipal broadband in different forms are very common here in Sweden, its not the only option. There are some areas of cities or certain estate owners that have deals with ISPs where they install the fiber and have exclusive right to sell broadband services. This can happen in cities with municipal broadband, so different areas of a city can have different providers.

The most common form of municipal broadband here is that the company that manages the water and electricity in the city (a company owned by the city but are run to make a profit) also installs fiber cables (is a network operator). They are going to dig up streets anyway, right? I have never seen a fiber cable above ground in my life here. They manage the cables and install switches etc to get the signal from the customers home to a central location in the city where it can be handed over to the ISPs. The company is not an ISP and does not sell any services in the network, but they allow any ISP that want to sell services with their infrastructure to do so. More and more this is done by standardized APIs (since one ISP can sell services within many different fiber networks), but also more manually with web portals for smaller companies or for troubleshooting etc. The ISP usually pays the network operator for number of subscriptions and/or changes done (connections/disconnections etc). The ISP can then sell services to customers and compete with the others both on price but also on how good their support, bundles etc are. That means that in a medium sized city (for Sweden at least... ~150k residents in my hometowns municipality) there can be up to 20 different ISPs that you can choose between and compare in a portal. All with the same cables and one ethernet jack in the apartments (or a fiber box in houses). Any ISP can deliver the service within a few minutes. So while the municipality has a hand in the fiber market they are not a competitor to the private companies, they simply enable the ISPs to compete in an open market to the benefit to the customers. The same model is used for electricity aswell. One fee goes to the municipal company that manages the physical infrastrcuture and the electricity meters while the cost of the actual electricity used go to the private company you have a contract with. This is the Open Acces Network model and is very common here in Sweden. There are also open networks operated by private companies. For example both Telia (which is both a network operator and a big ISP, previously state owned now privateized) and Telenor (the same deal but from Norway) operate both open networks and "closed" networks (where they have a monopoly).

There is also another, less common, model where the municipality has created a separate company that places physical fiber cables under the streets but does not offer an active network (dark fiber). This model is used by Stokab in Stockholm and was in part created to prevent too many distruptions by private companies constantly digging up the streets. Then all ISPs can rent fiber on equal terms.

tl;dr: Fiber cables are in many places in Sweden handled like a utility and private ISPs can all use them to sell their services to customers on equal terms which create competition that is great for the end user.