All perfect praise be to Allaah, The Lord of the worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad, sallallaahu ‘alayhi wa sallam, is His slave and Messenger.
If you mean the obligatory charity (i.e. Zakah), then it is better than ‘Umrah without doubt. However, if it is voluntary charity, then, in principle: Hajj and ‘Umrah are better since they involve spending money along with other acts of worship like Tawaaf, Sa‘y, Thikr, prayer, and Talbiyah.
Nonetheless, if there are people who are in need of a person's charity or if he has needy relatives and he cannot combine giving charity and performing Hajj and ‘Umrah, then charity is better in such a case.
On the other hand, An-Nasafi, the Hanafi scholar said: "Hanafi scholars said that voluntary Hajj is better than charity."
Al-Hattaab, the Maaliki scholar said: "Maalik was asked whether he preferred Hajj or charity and he replied saying: "I prefer Hajj, unless it is a year of famine."
Moreover, Shaykh Al-Islam Ibn Taymiyyah said in Al-Ikhtiyaaraat: "If a person has needy relatives, giving them charity is better and so is the case if there are people who are in need of his charity. If both Hajj and charity are voluntary, then Hajj is better because it is an act of worship that combines both physical and material aspects. Likewise, offering Udh-hiyah and ‘Aqeeqah is better than giving their value in charity."
In Nayl Al-Awtaar, Ash-Shawkaani said in his commentary on the Hadeeth of the best deed ever where the Prophet, sallallaahu ‘alayhi wa sallam, mentioned belief then Jihaad then Hajj. [Al-Bukhari and Muslim], Ash-Shawkaani said: "This Hadeeth is proof for those who view that voluntary Hajj is better than charity."
One who ponders over the conditions of the Ummah nowadays realizes that there are many people in need of charity. There are many Muslims all over the world who cannot find food, drink or residence. Thus, giving charity to such people takes precedence over (voluntary) Hajj and ‘Umrah.Allaah Knows best.