This has been my party's experience - your campaign assumptions may vary. The party has levelled from 1 to 8 in the Forgotten Realms North, but "my" realms, and I make NPC level assumptions a bit differently. Firstly, NPCs do gain levels, and levels 1 to 3 are considered apprentices. Most experienced professionals (in any profession) are levels 4 to 6, with plenty of level 1 to 3 newbies, and a more rarified strata from 7 upwards. Basically 4 to 6 is 'competent', 7 to 9 is premier or boutique, and up is powerful advisors, rulers, or superstars / celebrities etc. Not to say that there can't be a second level baker, soldier, noble, or King, but they would be young, and considered inexperienced enough to need trainer wheels until they learned a bit more. I say all of this to highlight one concept frequently mentioned that doesn't apply in my campaign - that
PCs of medium level can just use force to not pay the 'cost' of society (being loosely defined as any group of people that identify as being a group)
whilst getting the 'benefit' (even if it is ony a bunch of people to talk to, trade with, and give meaning to why the PCs are doing something).
So, the force the town guards bring to bear may be more of a consideration in my campaign for longer than 'default' D&D - even if I freely admit that my level 8 PCs, with their far superior equipment, classes, and stats can slay twice their number of 'average' town guard without a loss.
If one factors in 'special' units - the 12 level adventurers related to / allied with / just plain old friends with the local authority, enforcing the authority's will is not
such a problem.
The PCs have adventured in only 2 (!) environments - 2 villages / frontier style areas, and one Metropolis (Waterdeep - Yay!). In the metropolis they were very much "off the wire". They lived as much in secret or as anonymously as they could, conducted running battles with a criminal organisation, did not come to the attention of the authorities, and participated almost exlcusively in the black market - taking gear from the dead, and selling it quickly for cash around the city. They did however become aware that others (especially property / business owners) paid taxes, that there was a 1 gp tax on all swords sold, and were taxed directly when entering the city with a cart.
In the village / wilderness situations, the PCs were much more in contact personally with the local authority. They paid tax - throughout the less developed North the 'rule of war' applies: any adventurers or other commission style expeditionaries pay 10% of the market value of what they take as booty to the village or town. This may be in addition to being paid, i.e. you get paid 100gp each to defeat the goblins, and 10% of what you find goes to the town; or it may be a true commission - we need the goblins taken out - if you do it you can keep 90% of their gear (which they took from us or travellers in the first place). This assumes that the area or problem being looted by the PCs is at least nominally recognsed as being 'the athority's', either by convention or law.
The 10% is calculated as a matter of honour, not bean counting. Both the PCs and the ruler eyeball the gear, agree to it's rough worth, and the party give gear worth 10% of the total to the rulers. (Out of character the players often work out the amount to the copper, but in character the principle applies).
The fact that the system is just accepted by all the NPCs that the party meets, and the rulers don't even 'demand' 10% - it's simply understood that they get it, means that the party, whilst it looks whistfully at the money going out the door, accept that this is just how the world works - much like we accept that our employer taking tax from our pay to send to the government is just how our world works.
Of course, the feudal nature and personal interaction inherent in society does have an effect, and produces some specific benefits for the authority, and the PCs.
The authority gets problems solved, either for free, or for an amount subsidised by the taxes. In the process of getting problems solved the authority acquires wealth! This can be used for fortifying the castle walls, feeding the people, or just a fancy new magical feather duster. The authority also enriches some powerful allies, who if the relationship progresses well, feel inclined to support or defend the authority.
The adventurers get massively enriched - they might be losing 10%, but they gain 90% - without having to argue about it, fight to keep it after fighting to get it, or be expelled or shunned - or kill good people just doing their job (the guards - if good

). They also usually gain the favour, the real, heartfelt grateful favour, of an important person in the region, who relies on them, trusts them, and supports and defends them.
In game, in the current village/ town, the PCs started with a semi hostile relationship, and have brought in such money whilst solving such problems (and being generally nice, even though they were boorish initially) that the ruler and they have a great and friendly relationship, and they can count on the ruler's support, protection etc.
So, to get back to the point - yes, my PCs, in the right circumstances pay taxes, and all of the guff above was trying to point out that it is not so crazy that they do so, and that players can accept it, and get more fun from the game sometimes from the implications of paying taxes.