In the large saute pan, melt the butter. Add onions and cook over medium to medium-high heat until onions start to caramelize. Add the garlic and saute until garlic starts to turn golden.
Reduce heat to medium-low. Add the spinach and sprinkle with salt and pepper. Saute for 3 or 4 minutes. Add the cream. Bring the mixture to a boil and reduce to a simmer. Simmer for 8 to 10 minutes, until the cream thickens.
Remove from heat and transfer into the prepared baking pan. Sprinkle the top with cheese and place in the oven. Bake for about 8 to 10 minutes or until cheese is slightly brown and bubbly.