Of course, you will have classic standbys like ketchup and mustard but why not take your burger game to the next level with toppings like Onion Jam, a sweet and savory jam comprised of soft onions with a little bit of bite, some mild heat from the black pepper, and a depth of sweetness and rich flavor from the balsamic vinegar. It goes really well with Bacon Jam, which both dress up just about any grilled meat or vegetable. After your guests polish off your onion jam, you just may have to rename it, “Ally Yum!” (Get it? Allium.)  Trust me, you’ll be making this onion jam for every backyard BBQ you host this summer. Now that you have a star burger condiment for your summer gathering, here is a guide on how to grill the best burgers too.

What is Onion Jam?

In terms of consistency, it is not unlike a fruit preserve, as the pieces of diced onion are intact and still look like an onion. The jam will be spoonable like a fruit preserve, and it will make an ideal accompaniment to your favorite burger patty, a cheese board, or as a topping for both a tart and focaccia. Several of the deeper, base note flavors, such as black pepper, red wine vinegar, and balsamic vinegar, are lifted and brightened by using fresh thyme, lemon juice, and lemon zest. The acidity from the lemon juice adds another layer of tartness, while the lemon zest—a highly underused ingredient—has a sweet aroma, both of which provide balance to the dish. Similar to making a fruit preserve, we’re macerating the onions to extract and use their liquid and its flavor. Although macerating isn’t the most accurate term—technically, we’re brining when using salt—we’re in the realm of jam-making with this recipe, so that’s the term we’ll use. The onions will cook down more gently in their own macerating liquid. Additionally, we’re not looking to caramelize the onions here, as that would give us a different flavor, and reduce the volume of the finished dish.

Keys to Success

There’s nothing tricky about making onion jam, the most important aspects are time and patience. Here are a few tips in order for you to make a great condiment:

The balsamic vinegar is the all-rounder here: it provides us with flavor, richness, and unique color.Once the onion mixture begins to change texture, the process moves swiftly, but not too much. If the jam seems to be cooking too quickly, simply turn the heat down slightly, and take your time. The recipe process is forgiving and allows for you to cook at a slower pace.With all of the sugars in this recipe (onions, balsamic vinegar, and granulated sugar)—this is not a dish to walk away from. You should be at the stove from start to finish.You want soft-soft peaks. Similar to the texture of a loose whipped cream, then we know we’re done cooking. The onion jam will setup even more like soft peaks when it has cooled.

Swaps and Substitutions

The flexibility of onion jam allows for adjusting to what’s at-hand in the kitchen. Here are a few swaps and substitutions you can try:

Yellow onions tend to be sweeter, but if you have red or white onions on-hand, you can use those too. There’s no difference in flavor in cooking onions as we do in this recipe.Swap apple cider vinegar or distilled white vinegar for the red wine vinegar. Red wine vinegar has a deeper flavor, but what we’re really after from the vinegar is the acidity.Use 1/8 teaspoon of ground clove instead of ground black pepper. Ground clove gives a base note flavor more associated with warmth than the mild heat from black pepper.Swap 1 tablespoon of rosemary for the thyme leaves.

How to Store Homemade Onion Jam

Once the onion jam is cooked, transfer to a glass jar or plastic container, and store in the refrigerator. The onion jam will keep refrigerated for up to two weeks, or in the freezer in ice cube trays. Add black pepper and 1 tablespoon of thyme leaves to the onions. Stir to combine. Reduce the temperature to medium-low and add the red wine vinegar and balsamic vinegar. Cook for about 10 minutes, stirring occasionally. At this stage, the vinegars will have cooked down and into the onions. The mixture will have become thicker and heavier in the pan. Cook, for about 15 minutes or until you can pull a heat proof spatula through the onions leaving a path, and the mixture slowly comes back together. Stir occasionally, being careful the mixture doesn’t stick to the pan.