Step #1 In a heavy 5- to 6-quart kettle heat oil over moderate heat until hot but not smoking & cook onions with thyme & salt & pepper to taste, until golden, stirring every once in awhile, about 15 mins.
Step #2 Reduce heat to moderately low & cook, stirring frequently to keep from scorching, until golden brown.
Step #3 Remove kettle from heat.
Step #4 While onions are cooking, bring a large saucepan of salted water to a boil for potatoes.
Step #5 Peel potatoes & cut crosswise into 1/4-inch-thick slices.
Step #6 Add potatoes to boiling water & cook 5 mins from time water returns to a boil.
Step #7 Drain potatoes well in a colander.
Step #8 Preheat oven to 425°F & lightly oil a 2- to 2 1/2-quart gratin dish or other shallow baking dish.
Step #9 Arrange half of potatoes, overlapping slightly, in dish & season generously with salt & pepper.
Step #10 Cover up potatoes with onions, spreading evenly, & top this with goat cheese.
Step #11 Arrange remaining potatoes, overlapping slightly, over cheese & season generously with salt & pepper.
Step #12 Dot gratin with butter.
Step #13 Gratin may be prepared up to this point 2 hrs ahead & kept at about room temp, covered.
Step #14 Pour milk evenly over potatoes & bake 35 mins, or until potatoes are tender & top is golden.
Step #15 Gratin may be made 1 day ahead & chilled, covered.
Step #16 Reheat gratin before serving.
Enjoy the Potato, Caramelized Onion, & Goat Cheese Gratin recipe