How this calculation works
Gross foreign dividend × NBP average exchange rate (the business day before the pay date) = gross amount in PLN. Polish tax due is 19% of that. The foreign tax credit is capped at the lowest of: the tax actually withheld abroad, the treaty rate for that country, or the Polish tax due itself — never a full offset above the treaty cap. What's left after the credit is what you owe Poland. See the full guide linked below for the reasoning behind each step.