Both are containers, but a sac is for plants and animals, and a sack is for a sandwich. So spiders put their eggs in a sac, and people put their groceries in a sack.

A sac is usually biological — attached to a living thing. At the end of E.B. White's, Charlotte's Web, Charlotte, the dying spider, says, "This is my egg sac, my magnum opus, my great work."

Sacs aren't just for spiders, though. Humans have them, too:

 "The identical twin girls shared an amniotic sac and placenta." (Washington Post)

"It damages air sacs and passages to the lungs, and can make breathing a struggle." (BBC)

Add a "k" to make sack and you've got yourself another name for a bag you can put your groceries in. You might have a sack of flour in your kitchen. Soldiers can also sack entire villages, as in raid them. People also sack quarterbacks and needless employees. Here are some examples:

"Within earshot, Meser, a 32-year-old farmer, sat on three sacks of rice with two cans of oil resting by his feet." (New York Times)

"Attitudes hardened after the sacking of Constantinople, the centre of the Orthodox empire, by Crusaders in 1204." (The Guardian)

"Every team that passed me, I was thinking how I'm going to sack their quarterback." (Salon)

They sound exactly the same, and they both contain something, but sac is more specific and rare than sack. You put your snack in a sack.