Take the bird out of the fridge at least 4 hours before cooking to bring it up to room temperature. To make the glaze, combine the butter, sugar, garlic and leaves from 2 thyme sprigs in a bowl. Season generously. Starting from the neck end, gently slide your fingers under the turkey-breast skin so that you can spread half the butter mixture over the flesh. Put the remaining butter mixture in a small pan with 50ml (2fl oz) of the Madeira and melt over a gentle heat. Set aside.
Preheat the oven to gas 5, 190°C, fan 170°C. Stuff the cavity with the halved onion and remaining thyme, and fill the neck cavity with the stuffing, securing with a skewer. Weigh the stuffed turkey and calculate the cooking time at 20 minutes per kilo, plus 90 minutes.
Put the sliced onions in a sturdy roasting tin, lined with a double thickness of foil, and sit the bird on top, breast-side up. Brush the melted Madeira-butter over the skin, then pour 300ml (½pt) Madeira around the turkey with 200ml (7fl oz) water. Cover loosely with more foil and roast for around 3 hours 15 minutes, until the juices run clear when you pierce a leg with a knife. Remove the foil 20 minutes before the end to brown the skin. Once cooked, transfer to a serving plate and discard the onion and thyme. Tent loosely with foil and rest for 30 minutes.
To make the gravy, remove the foil from the tin, leaving all the juices and onion behind. Spoon the fat out then place the tin over a direct heat and add the flour. Stir with a wooden spoon, gradually add the stock and 100ml (3½fl oz) Madeira to form a smooth sauce. Bring to the boil and simmer briskly for 5 minutes to reduce. Strain into a jug, pushing the onions through with the back of a spoon. Season and serve hot.
Turkeys are currently available in your local Tesco store
For top tips on protecting you and your family when preparing raw meat and poultry, visit Food Safety in the Home and view the full Food safety at home video.