In The Name of Allaah, The Most Merciful, The Bestower of Mercy.
Allaah [The Exalted] said:
وَلَنَبْلُوَنَّكُمْ بِشَيْءٍ مِنَ الْخَوْفِ وَالْجُوعِ وَنَقْصٍ مِنَ الأَمْوَالِ وَالأَنْفُسِ وَالثَّمَرَاتِ وَبَشِّرِالصَّابِرِينَ
ٱلَّذِينَ إِذَآ أَصَـٰبَتۡهُم مُّصِيبَةٌ۬ قَالُوٓاْ إِنَّا لِلَّهِ وَإِنَّآ إِلَيۡهِ رَٲجِعُونَ
أُوْلَـٰٓٮِٕكَ عَلَيۡہِمۡ صَلَوَٲتٌ۬ مِّن رَّبِّهِمۡ وَرَحۡمَةٌ۬ۖ وَأُوْلَـٰٓٮِٕكَ هُمُ ٱلۡمُهۡتَدُونَ
And certainly, We shall test you with something of fear, hunger, loss of wealth, lives and fruits, but give glad tidings to As-Sabirin (the patient ones, etc.). Who, when afflicted with calamity, say: “Truly! To Allah we belong and truly, to Him we shall return.” They are those on whom are the Salawat (i.e. blessings, etc.) (i.e. who are blessed and will be forgiven) from their Lord, and (they are those who) receive His Mercy, and it is they who are the guided-ones. [Surah Al-Baqarah. Verses 155-157]
Anas Bin Maalik [may Allaah be pleased with him] reported that the people said, “O Allaah’s Messenger! Prices have gone up, so fix prices for us”. So, Allaah’s Messenger [peace and blessings of Allaah be upon him] said, “Allah is the one Who fixes prices, Who withholds, gives lavishly and provides, and I hope that when I meet Allah, none of you will have any claim on me for an injustice regarding blood or property”. [Saheeh Sunan Abee Dawud. Number 3450]
Shaikhul Islaam Ibn Taymiyyah [may Allaah have mercy upon him] said: High increases in prices and their decreases are among those events that none brings about except Allaah alone and nothing can occur from it except by Allaah’s Will, but He [Glory be He and free is He from all imperfections] has made some of the actions of His slaves the cause of some incidents, just as He made the deed of killing of a killer a cause of the death of the victim, and the increase in prices may be due to the injustice of the people, and the decrease may be due to the benevolence of some people. (1)
Pay attention to the statement of Shaikhul Islaam as follows, “….the increase in prices may be due to the injustice of the people, and the decrease may be due to the benevolence of some people”. Indeed, it is common knowledge in our era that farmers – in some wealthy nations – are sometimes ordered to dump good produce. This is due to a number of reasons: firstly, sometimes capitalists do not have in place a system that would allow farmers to grow only what is enough, therefore they are left with no choice but to dump some of their produce. However, despite this overproduction, many people are still unable to afford good quality food. One of the ways this can be avoided is if governments help charities to repackage and redistribute excess food to those in need of it. Secondly, sometimes the greedy capitalists solely desire to make profit regardless of the consequences. For example, there has been incidents – in some wealthy nations – when farmers were ordered to depopulate their livestock to inflate prices, whilst many people were unable to put meat on their tables. This is nothing but an act of conspiring with farmers to create scarcity and thus unveils one of the negative outcomes of a capitalist economy.
The Hoarders: Muammar Bin Abdillaah [may Allaah be pleased with him] who said that the Prophet [peace and blessings of Allaah be upon him] said, “None hoards except a sinner”. [Saheeh Muslim. Number 1605]
Imaam Abdul Azeez Bin Baaz [may Allaah have mercy upon him] said: They are the ones who buy commodities, such as food and the like that people need in times of hardship, and he stores it so that when the price is high he sells it for more. This is not permissible and it is an evil deed, and the one who does this is a sinner. If there is one in charge of authority in the country, It is obligated on him to implement the affairs related to the Sharee’ah, and it is obligated on the one in charge of authority to prevent him from doing so, and compel him to sell food at the same price – at the current price that is in the markets; and he cannot hoard it if it is during the time of hardship. As for the one who buys food or other than food that people need in a time of prosperity and abundance in the markets, and not to harm anyone, then when trade begins, he sells it with the people without delaying it until when a state of extreme need occurs, rather, he sells when the trading begins and there is benefit, there is no objection to this action of his. This is work of merchants in ancient and modern times. (2)
Imaam Muhammad Ibn Saaleh Al-Uthaymeen [may Allaah have mercy upon him] said: It is forbidden to monopolize (or hoard) what people are in need of. The Prophet [peace and blessings of Allaah be upon him] said, “”None hoards except a sinner”. This is a person who deliberately commits a sin. But monopolizing (or hoarding) is only in relation to what is not found with anyone else other than this monopolist (or hoarder). As for what him and someone else possess and he wants to keep the commodity until its season comes, then there is nothing wrong with this and this is not considered a monopoly (or hoarding). For instance, if a person buys rice and says: I will save it until the time of its season, whilst the people have rice and they sell as they want, then this is not considered a monopoly (or hoarding); but it is not found except with him, and he is saves it until the time of high prices comes, then indeed this is monopolizing (or hoarding). The scholars said that the one in charge of authority is obliged to force the monopolist to sell what he has monopolized (or hoarded) just as people sell at the time they need to sell because this is in the public interest. (3)
[Ref1:Majmoo Al-Fataawaa 8/520]
[Ref 3: https://binothaimeen.net/content/11952. paraphrased]