French Onion Potatoes au Gratin

Slightly adapted from Life is a Party

6 T. canola oil, plus more for greasing
3 lg. onions (about 2¼ pounds), quartered, thinly sliced
Kosher salt and freshly ground black pepper
2 garlic cloves, minced
6 to 8 Yukon Gold potatoes (about 2½ pounds), peeled, very thinly sliced
12 oz. Gruyere cheese, shredded
2½ c. half-and-half

In a large straight-sided skillet, heat the canola oil over medium heat. Add the onions and a large pinch each of salt and pepper and cook, stirring occasionally, until the onions are sticky, tender, brown, and nearly jammy, about one hour. If the onions stick to the pan at any time, add a tablespoon of water and use a wooden spoon or heatproof spatula to scrape up any browned bits from the bottom of the pan.

Stir in the garlic and cook, stirring occasionally, until fragrant, about five minutes. Turn off the heat and let the caramelized onions cool slightly. (The caramelized onions can be made the day before and stored in an airtight container in the refrigerator.)

Preheat the oven to 400° F. Brush a 9” x 13” baking dish with canola oil.

Lay 1/5 of the potatoes over the bottom of the pan. Season the potatoes with pinches of salt and pepper. Sprinkle 1/5 of the caramelized onions, followed by 1/5 of the Gruyere, then pour 1/2 cup of the half and half and 1/5 of the cheese. Repeat this process four times.

Place baking dish on a large baking sheet and bake until a wooden skewer inserted into the middle meets no resistance or the top is bubbling and browned, about 1 hour 30 minutes, rotating the pan halfway through the cooking time.

Remove from the oven and let sit for at least 20 minutes and up to an hour to solidify before slicing into pieces and serving.