I always keep a jar of caramelized onions & garlic in the fridge. I love it on toast, pizza, mixed into salad dressing, or as a base for onion soup. In a sealed container, the mixture will keep, refrigerated, up to 3 weeks.
Find it online: https://soffiawardyrecipes.com/caramelized-onions/