prescription medications really don't expire.
I've never ran across problems using "expired" OTC pain meds/NSAIDs.
I cannot imagine it is any different for caffeine.
Chemicals really don't expire. Maybe a decade later some of the total amount of the chemical has broken down so effectiveness diminishes, but I don't really even know about that. Maybe some of the compounds used in the pill to make it an actual pill will start breaking down. Maybe the glycols and cellulose-type compounds start breaking down after a lengthy amount of time, but unless those break down into toxic chemicals, I don't think there is a problem.
I think medications basically have those expiration dates mainly because it's law. Kind of covers the company's ass just in case there is something they had no idea about as a potential decomposition issue.
Based on all the information I've come across online about various medications and expiration dates, I'm convinced there is no issue for most products. I'm still alive after who knows how many "expired" pills, be them OTC or prescription.
The only thing that I won't use after the expiration date would be eye drops. Most likely safe but there really aren't any safety buffers for the eyes for me to apply my gamble to them.