This may sound silly, but once a week I hide my credit card away for a full 24-hours. This simply means that I cannot spend anything on my card that day.
This does not stop me buy things that I really need as I can obviously get them the following day; but “silly” things that I would sometimes buy become irrelevant when I can’t buy them.
Give it a try and just don’t spend anything on your card for a full 24 hours. It’s best if you physically hide your card somewhere. It’s actually really easy to do and the rewards may seem small but in the long run every small bit adds up. Not only the physical money but also the mental observance of what is really important and what is not.