In the countries that I am familiar with (such as Canada), using barter to avoid taxes is definitely illegal. You are required to report the dollar value of the exchange as revenue. It is treated as an implicit trade of cash along with the trade of goods. Since I am not going to give tax advice to random strangers on the internet, please consult the tax laws of your jurisdiction.
Canada Revenue Agency guidance on barter: link to CRA page
There are exemptions, such as for little kids trading cards on the playground. The idea is that you cannot be earning a livelihood.
The authorities can detect this activity the same ways that they can detect people working for cash. It’s not easy, but it can be done. They can have undercover agents, get tips from whistleblowers (e.g., a bitter divorce), or just show that a person is living a lifestyle that is not in line with their declared income. Advertising that you accept barter is a pretty good method to ensure that you will eventually get a visit from an undercover inspector, or just a tax official who sees your advertisement.
Since tax evasion this way has to be hidden, an outsider cannot tell if it is going on. So it is obviously hard to judge its extent, other than by looking at successfully prosecuted cases.
Since businesses need to pay taxes (and most expenses) with money, barter does not help them meet those obligations. However, it has its uses. For example, a new firm will likely not be profitable for some time, so it will have no tax payments due. It might use barter transactions to preserve cash. Established suppliers might agree, as they want a new potential customer to succeed.
But since retail firms have to pay value-added taxes (sales taxes) with money, they have no incentive to offer customers the ability to barter. Furthermore, those customers could be tax inspectors.
A value-added-tax (VAT) also does a good job of providing a disencentive for such activity. An intermediary firm can get a refund on the VAT it paid for inputs by matching the inputs to the VAT paid on outputs. (That is why it is called a value-added tax.) Your ability to match the taxes is eliminated by tax evasion. And inspectors can tell whether retail firms (the usual end of the value-added chain) are charging households VAT. (In Quebec, the authorities made restaurants install new cash register systems that made it extremely difficult to run two sets of books, which was a common practice.)
Some added points on incentives.
- For a firm, all cash outlays (other than dividends) will eventually be expensed against income tax. Barter is not really advantageous. It has legitimate business purposes, and there was a niche industry in building barter internet hubs. However, there will still be a paper trail.
- When dealing with individuals, there is the “double coincidence of wants” problem. If a plumber comes to my house to fix a leaky valve, what exactly can I offer in return? If he wants to avoid tax, he will normally just ask for cash. Barter certainly happens among individuals, but it requires that they have a reciprocal need for the other’s services.