It's a long term thing, like over a couple of years, so that your body reacts less aggressively to allergens.
I had allergy shots as a child and also in my early 20s. I guess they worked okay. But, in all honesty, I don't know how my allergies would have been if I hadn't gotten the shots.
======================
Now, a thing I didn't learn until my early 40s, is that antihistamines work by blocking receptor sites. So, if I'm going to take Allegra which is an over-the-counter, non-drowsy causing antihistamine, and which I do take, I can't just pop one and expect immediately relief of itching eyes and throat and post nasal drip. I have to kind of anticipate and take it for a couple of days.