Preheat your oven to 375°F (190°C).
Cook green beans: Bring a large pot of salted water to a boil. Add green beans and blanch for 3–4 minutes until tender-crisp. Drain and set aside.
Prepare sauce: In a large skillet, melt butter over medium heat. Add sliced mushrooms and cook until softened, about 5 minutes.
Add garlic and sauté for 1 minute until fragrant.
Make roux: Sprinkle flour over the mushrooms and stir to coat. Cook for 1–2 minutes to remove the raw flour taste.
Add broth and cream: Slowly whisk in chicken or vegetable broth and then heavy cream. Continue whisking until smooth.
Season: Add salt, black pepper, and nutmeg if using. Simmer for 2–3 minutes until sauce thickens.
Add cheeses: Stir in cheddar and mozzarella until melted and incorporated.
Combine: Add blanched green beans to the sauce and stir gently to coat.
Transfer to baking dish: Pour the mixture into a greased 9x13-inch baking dish.
Top with onions: Sprinkle French fried onions evenly over the top.
Bake: Place in the preheated oven and bake for 20–25 minutes, until bubbly and golden brown on top.
Serve warm and enjoy!