Depends on the jurisdiction where you physically reside, but most likely your country can claim the offshore company is actually a company based in your country of residence and tax it accordingly.
If you have employees offshore, a director offshore, quarterly shareholders company meeting offshore and the income is not coming entirely (or, even better, not at all) from your country of residence, then maybe it will be just sheltering (subject to the laws in your country of residence that can change at any time).
I've been thinking of setting up a company in a low tax location (non blacklist, maybe 5-12%), receive payments for a group of contractors working with foreign companies in high tax jurisdictions (think, living in Spain for a US or UK company) and then keep a ledger of payments received, expenses and money paid out. Company shares could be granted among the contractors and the manager of the company based on how much the contractors brought into the company and invoices for work (and dividends) could be paid to the contractors who need some money to live.
The money left in the company could be invested for the contractors in whatever they prefer.
After a decade working and saving outside of your expensive jurisdiction you could move to some tax friendly location (Dubai, or Portugal under the NHR scheme) and extract all the profit you made over your career.
If the contractors were all shareholders and going to shareholders meeting in the offshore location, there may be enough substance to keep tax collectors at bay and having multiple people bringing income would make it hard for the authorities to claim they could tax the offshore company as a national company.
The price to pay would be trusting the managers of the company not to run away with your money and to respect the contract.