Peel and thinly slice the potatoes, and peel, halve and finely slice the onions. Pick the sage leaves and finely slice most of them, leaving some whole.
Arrange a layer of sliced potatoes over the base of a 20cm x 30cm baking dish, followed by a layer of sliced onions, a scattering of sliced sage and a pinch of sea salt and black pepper. Keep alternating layers of potatoes and onions, lightly seasoning each layer and finishing with a layer of potatoes that slightly overlap each other.
Pour over the stock, season the top layer with a little salt and pepper, then scatter over the whole sage leaves and grate over the Parmesan.
Pop little dots of the butter all over the potatoes, then bake at the top of the oven for 1 hour, or until the top is golden and the potatoes are cooked through.