The Latin loanword ex post facto, meaning literally from that which is done afterward, has come to mean after the fact in English. It can convey pomposity in less formal contexts in which the phrase after the fact or synonyms such as retroactive would work fine, but it does have legitimate uses, especially in legal contexts. It’s usually used as an adjective, but it also works as an adverb—for example:
The Swiss Supreme Court will intervene ex post facto only on restrictive grounds . . . [International Law Office]
They were hearings ex post facto, held to gather input on a proposal that is not a proposal at all, but rather the law of the District of Columbia. [Washington Post]
In an opinion by Walker, the majority found to be “without merit” the ex post facto claim, but only after citing United States v. Rodriguez . . . [Law.com]
And the phrase is occasionally used in non-legal contexts:
Later in the day, National Oceanic and Atmospheric Administration (NOAA) and Environmental Protection Agency (EPA) regulators . . . gave an ex post facto clean bill of health to the spill response’s heavy use of the chemical dispersant Corexit 9500 . . . [World Socialist Web Site]
That sort of scenario was not the ex post facto invention of a Hollywood screenwriter. [Salon]
As shown in these examples, some publications italicize ex post facto and some don’t. And because this loanword is a relatively common set phrase, it does not need to be hyphenated like most phrasal adjectives.