It depends on the country where you live.
the funds for Unemployment Compensation are derived from the taxpayer`s gross income.
On the other hand,
in Canada every Canadian workers pay 1.73% of insured earnings for the benefits that they could get once they lose their jobs.
The employers also contribute 1.4% of the employees` premiums.
So in general,
employment insurance is derived from the taxes you pay while you are working but if you got the insurance and you exceeded the eligible amount,
you will need to repay it once you are employed again.
The payment is on a monthly basis and it will depend on the amount you owe from the government,
and you will receive a monthly statement of account for making this payment.