Preheat your oven to 400°F. Firmly hold each garlic head at its base and carefully slice off about ¼ inch from the top to expose the cloves. Ensure every clove is visible, removing some of the outer papery layers if needed. For cloves located along the edges, use a paring knife to trim their tops. Repeat this process for any additional garlic heads you plan to roast.
Place the prepared garlic heads in an oven-safe stainless steel pan or skillet with an oven-safe lid. Choose a pan with a base wide enough to keep the bulbs from touching the sides. Drizzle each garlic head with 1 to 2 teaspoons of olive oil, ensuring the exposed tops are well coated. Use your fingers to redistribute any oil that settles at the bottom back onto the tops of the bulbs.
Cover the pan and bake the garlic for 40 to 70 minutes, checking for doneness every 10 minutes once the initial 40 minutes have passed. Be cautious while handling the hot pan. The garlic is perfectly roasted when the tops are golden brown, and the cloves are tender enough to be easily pierced with a paring knife. For a richer flavor, you may roast an additional 5 to 10 minutes, but monitor closely to avoid burning. Signs of burning include a sharp acrid smell or blackened cloves.
Allow the roasted garlic to cool for at least 10 minutes, or until it’s safe to handle. To extract the roasted cloves, use a fork, a grapefruit spoon, or gently squeeze them out from the base, which works especially well for inner cloves.
Use the roasted garlic immediately, or store it promptly. Refrigerate it for up to 4 days, or freeze it for several months in labeled containers. Avoid leaving roasted garlic at room temperature, as botulism toxins can develop rapidly in such conditions.