Any spice is gonna lose potency over time. Keeping 'em sealed, more or less airtight, is gonna help, but not completely fix it. Realistically, just taste it, see how it works in recipes. If it's still potent enough for your needs, keep using it. Maybe use more if it's starting to weaken a little. If it's just not doing it anymore, and your recipes keep coming out bland and lifeless, then yeah, it's probably best to toss the Smoked Paprika that says it was bottled in "Czechoslovakia."
There's some regional and brand variability, both in terms of quality and even taste. Mexican oregano is a pretty different herb than traditional European oregano! And a lot of cheapo brands of, say, garlic powder are gonna let a lot of substandard garlic and garlic skins into the mix before it's dried and ground up.
For whole spices, I wouldn't worry as much, but even there. . .
(like, none of this is gonna make or break a recipe, tbh. But if you want the best possible flavor, buying high-quality, fresh spices from reputable dealers is gonna be one component of that process. If you're slapping together some man-chow to pour down your gullet between rounds of LOL, the Wally World cumin's gonna work just fine. I say, with a bottle of Wally World cumin in my spice cabinet right now. . . about six inches under the nice Indian brand of whole cumin seeds :-D )