01 - Preheat oven to 375°F. Grease a medium casserole dish with olive oil or cooking spray.
02 - Heat olive oil in a large skillet over medium heat. Add onion and sauté for 2–3 minutes until translucent. Add garlic and cook for 1 more minute until fragrant.
03 - Add diced chicken to the skillet. Season with salt, pepper, thyme, and basil. Cook for 5–6 minutes, stirring occasionally, until chicken is no longer pink and is lightly golden on the edges.
04 - Reduce heat to medium-low. Stir in cream cheese until fully melted and the mixture is smooth and evenly coated.
05 - Add chopped spinach and cook, stirring continuously, for 2–3 minutes until completely wilted and incorporated into the mixture.
06 - Pour in heavy cream. Add half of the mozzarella and half of the Parmesan. Stir until the cheeses are melted and the sauce is smooth and creamy.
07 - Transfer the mixture to the prepared casserole dish, spreading it into an even layer. Top with the remaining mozzarella and Parmesan cheeses.
08 - Bake uncovered for 20–25 minutes, or until the sauce is bubbly around the edges and the top is golden brown.
09 - Remove from the oven and allow to rest for 5 minutes before serving. This helps the sauce set and makes for easier portioning.