I am undecided if UBI can actually be considered just. It doesn’t seem so. There is a form of justice called distributive, which the Catholic Encyclopedia describes as follows:
When it imposes taxes, military service, or other burdens; when it distributes rewards, offices, and honours; when it metes out condign punishment for offenses, it is bound to do so according to the various merits and resources of the persons concerned; otherwise the State will sin against that special kind of justice which is called distributive.
Paying all the same amount from tax revenue regardless of merit or need seems to violate this. Some distributions would necessarily be unjust. It seems to me a social insurance program based on need is more just in that regard.
St. Thomas says the following on distributive justice:
On the second place there is the order of the whole towards the parts, to which corresponds the order of that which belongs to the community in relation to each single person. This order is directed by distributive justice, which distributes common goods proportionately.
Again, UBI does not seem proportionate. I could see a situation, like certain middle eastern countries, where it makes sense for say, the oil industry to be owned and operated communally by public authority (cf. Quadragesimo Anno 114 which notes situations where this is rightly done) and the income from it is paid to the members of the community. Even then though an equal distribution is not a proportionate distribution necessarily, as it does not seem to take into account either merit or resources.
Plus, there is the principle in Scripture that if a man not work, neither let him eat. This of course does not apply to those who cannot work or mean that labor is the sole title to income, but rather someone should be denied if they refuse to work (cf. QA 57). UBI would not take this into account, not to mention paying someone with plenty of resources who refused to work. UBI would not serve the common good in such a case.
It seems regulating wages at a certain level and improving social insurance programs would achieve the same or better desired result for the less well-off, without the inefficiencies and injustices of making payments to the rich and/or idle.