Preheat your oven to 375°F and grease a 9x13-inch baking dish with cooking spray or butter.
Heat olive oil in a large skillet over medium heat. Add diced onion and sauté for 4-5 minutes until softened, then add garlic and cook for another minute.
Add chopped spinach to the skillet and cook until wilted, about 2-3 minutes. Remove from heat and let cool slightly.
In a large bowl, whisk together eggs, milk, salt, pepper, and red pepper flakes (if using) until well combined.
Stir in the sautéed vegetables and 1 cup of the shredded cheese, saving the remaining 1/2 cup for topping.
Pour the egg mixture into the prepared baking dish and sprinkle the remaining cheese on top.
Bake for 30-35 minutes until the center is set and the top is golden brown. A knife inserted in the center should come out clean.
Let cool completely, cover with foil, and refrigerate overnight. Serve cold or reheat slices in the microwave for 30-45 seconds on Christmas morning.