Some ethicists would argue that the acts you could possibly do with a bunch of money differ strongly in their moral value. For instance might giving the money to charity (assuming that the charity does not misuse the money, realizes effective projects etc.) save or improve the lives of children in dire circumstances. This arguably is of higher value than buying some good not necessarily needed for living.
This by itself does however not imply a concrete duty as to if and how much one should donate. The formulation of such a duty depends on the ethical framework one subscribes to. One well-known argument for donating is made by Peter Singer. Singer mentions that in our all-day we follow a principle of mutual assistance. That is, if some person we encounter needs immediate help which we can provide (without making impossible sacrifices, of course), we have a duty to help. He illustrates this principle with a story about a small child falling into a pond. If you walk past this child and see it almost drowning, you have a moral duty to help (also if you miss an appointment thereby, or your suit gets dirty).
Now Singer claims that in a global context, the same principle holds. If we can save a child in a poor country by donating some ten or hundred euros, we should do so.
(c.f. https://www.utilitarian.net/singer/by/1972----.htm; also see his Practical Ethics).
Of course this principle is somewhat underspecified in that it does not say where the exact border between the duty to help and the right to care for oneself lies.
The strongest opinion on this question is held by act utilitarians. They would say that in every decision moral value has to be maximized. So they would suggest to donate large amounts to charity. Singer later adopts this position in the mentioned texts.
Not everyone has agreed. Others, like Valentin Beck, hold that it must be possible for one to follow own life plans, which would restrict the possible scope of this principle. In Beck's view it is not wrong to spend somewhat more money on oneself than necessary for living if this contributes to a life plan one considers important. That is, he sets the border for a duty to help lower.
Of course some would also even argue that there is no or a very limited duty to help at all in the global context.
In my own (personal) view I am afraid of setting the border for helping to low - particularly due to the fact that I am convinced that living in dire circumstances means pain that is very difficult to imagine, and I am convinced it is inhumane to ignore most of this pain. The world has become a very small place. One should in my opinion also consider a second argument (also sometimes heard), namely that the life style in a western democracy might contribute to global misery and injustice.