I do that at least once a week. It depends on what it is and how it smells.
Eggs can last up to about a month after their “expiration” date, which is a month after they’re packed, I believe. If it’s something like milk or yogurt I won’t go more than a couple days. Cans I may go a year or two if they aren’t bulged and smell ok. Oh, and I only get sick once or twice a year, and as far as I know it’s never from food.