When and how do PS+ free games expire?

As soon as you download the game, it'll look into your ps plus subscription end date and put the expiry date on the game. You can check by hitting Options and the Information.

Looks like checks are periodical:

Your PS Plus status will need to be checked when a game is first played. After that, there will be a periodic check, which I beleive is in the region of each 30 days.

I didn't find any official sources, but multiple threads confirm.