Preheat the oven to 400 degrees F (200 degrees C).
Heat oil in a large skillet over medium heat and cook onion until soft and translucent, about 5 minutes. Season with salt, pepper, and thyme. Sprinkle flour over onion mixture and cook until a thick paste forms, about 1 minute.
Place spinach in a large soup pot and cover. Heat on low until spinach begins to wilt, about 4 minutes. Turn heat off and add half-and-half, 1 cup Swiss cheese, and the onion mixture. Stir to combine and transfer to a 9-inch gratin dish.
Combine breadcrumbs and remaining 1/2 cup cheese in a bowl. Pour melted butter over the top and stir to combine. Evenly spread breadcrumb mixture over the spinach.
Bake in the preheated oven uncovered for 20 minutes. Let cool for 5 minutes before serving.