Raw ground beef lasts around 2 days in the refrigerator and cooked ground beef lasts around 3 to 5 days.
If you want to keep the ground beef longer whether cooked or raw it should be frozen which will keep the bacteria from thriving which is what makes the meat go bad.
When frozen ground beef can last from 6 months to a year whether it's raw or cooked.