I accidentally ate some packaged shredded cheese without knowing its expiration date. It expired in December and it is now February. it tasted fine, and it wasn't moldy. will I be okay? or should I worry about being sick? if so, how long would it take for me to get sick? 
  It may well be a can of worms, but your question is very valid when, according to Wikipedia:     every year in the USA there are 76 million foodborne illnesses, leading to 325,000 hospitalizations and 5,000 deaths.   That aside, it is worth pointing out the facts about hard cheese and its longevity. Firstly it is a high fat product. Fat goes rancid, not bad unless it develops mould. Therefore if it looks mould-free, smells and tastes fine, there will be no problem. Indeed, even if the cheese has developed a mould, it does not necessarily mean it will make you ill, as the human gut has been made to deal with many moulds which naturally occur.  Historical facts: hard cheese was "invented" as a way of preserving a product made in times of plenty, to see over the times of hunger. The inherent properties and content (fat and salt) are long-life products which no amount of industrialisation can destroy. These cheeses include Cheddar, Parmesan, Emmenthal and Edam.  My personal experience: I currently have cheese in the refrigerator bought abroad and three-four months past its "use by" date. This happens regularly every year, because I cannot live without my Extra Mature Cheddar. At no time have we ever been ill as a result of eating out of date cheese. HOWEVER, it is not low-fat nor grated. If grated cheese is nearing its best-by date and you do not intend using it in the near future, simply pop it into the freezer.    Shelf Life A UK initiative to reduce food-waste may be of interest. WRAP (Waste & Resources Action Programme) is a registered UK charity working with "businesses, individuals and communities to achieve a circular economy through helping them reduce waste, develop sustainable products and use resources in an efficient way". It is pertinent that the whole "use by" labeling is being scrutinised. According to WRAP, 33% percent of all food produced is wasted along the cold chain or by the consumer. At the same time, a large number of people get sick every year due to spoiled food.   Which brings us back to your question of how long will it take before you get sick if the cheese was "bad"? The incubation period i.e. the time between eating contaminated food and the onset of symptoms, can be as short as a few hours or as long as several weeks. Hard cheese is less likely to cause serious food-poisoning, but Salmonella and Listeria and other bacteria may be found in a range of chilled, ready-to-eat foods including cheeses such as soft blue cheese, Brie and Camembert. It will also develop and grow in a refrigerated environment more information here It is also worth mentioning most deaths from food poisoning are from E.coli and Listeria, with the very young, the aged and those with a compromised immune system at greatest risk. 