Spanakopita can be prepared in advance. However, if possible, prepare it as close to when you plan to serve it as possible. This will ensure that the fillo dough is crispy, instead of limp and soggy. If you absolutely have to prepare the Spanakopita ahead of time, you can refrigerate the triangles overnight. If preparing them farther in advance, consider freezing them.