Peel and thinly slice the onions.
4 large yellow onions
Melt butter in a large Dutch oven over medium heat. Add onions and salt, cover, and cook for 5 minutes until softened.
4 Tablespoons butter, 1/2 teaspoon salt
Remove lid and cook onions, stirring frequently, for 40–45 minutes until deeply caramelized.
While onions cook, heat the stock in a separate pot and keep warm.
2 quarts beef stock
Add garlic, wine, and sherry to onions and bring to a boil.
2 teaspoon garlic, 1/2 cup white wine, 2 Tablespoons sherry
Stir in flour and cook for 1–2 minutes until coated.
2 Tablespoons all-purpose flour
Add warm stock, Worcestershire, thyme, bay leaf, and pepper. Simmer 10–15 minutes.
1 teaspoon Worcestershire sauce, 1 teaspoon fresh thyme, 1 bay leaf, 1 teaspoon pepper
Preheat oven to 400° F and toast bread until golden.
12 slices French bread
Remove the bay leaf, and ladle soup into oven-safe bowls, top with bread and cheese.
2 cups Gruyère cheese or Swiss cheese
Broil until cheese is melted and bubbly. Serve immediately.