In a large frying pan over medium heat, melt the butter with the olive oil. Add the sliced onions and cook until translucent, about 3 minutes. Reduce heat to low and continue cooking until onions are deep golden and caramelized, around 15-20 minutes. Stir in minced garlic and cook for an additional minute.
In a medium pot, combine basmati rice, chicken broth, and salt. Bring to a boil over high heat, then reduce to low. Cover and cook for 12 minutes. Remove from heat and let it sit covered for 10 minutes.
Reserve a portion of the caramelized onions for topping. Mix the remaining onions into the cooked rice. Add parmesan and gruyere cheese, stirring well.
Serve the French onion rice casserole with the reserved caramelized onions on top.
Notes
For a richer flavor, you can add a sprinkle of fresh thyme or rosemary to the dish before serving.