When planting rosemary in a container with companion plants, consider plants with similar watering and sunlight requirements. Good options include thyme, sage, oregano, and lavender since they all prefer well-draining soil and can tolerate dry conditions ^source^.