The "wantsies" can be a difficult siren song to resist! I'm not as successful at resisting as I would like to be, but a few things that help me when the shopping bug is biting me:
1) I unsubscribe from email lists, and if I'm seeing a particular type of sales ad recurring on my social media, I'll right-click and label it "irrelevant to me" (or however it's worded for a particular platform).
2) I pick one thing from my closet that doesn't get worn a lot, and I play with it. I challenge myself to make a new capsule module out of what I already have, using six pieces: two bottoms, three tops, and a topper. Sometimes one of those bottoms is a dress, and I try putting a sweater or blouse over it, and belting it.
3) Alyssa Beltempo has a wonderful playlist on her YouTube channel called Shop Your Closet, in which she shows you ideas to recreate runway or style influencer looks, with what you already have.
4) I pick something that I rarely wear, that lies more on the fantasy-life side of the closet, and I wear that around for awhile. When I get tired of it, I hang it back up and put on something else that I adore, but somehow never get around to wearing.
5) Sometimes, me just saying, "today is a great day to break a habit", and taking a book + beverage outside to read, with some pretty music or doing something else relaxing and enjoyable, helps immensely with the wantsies.