God is sovereign and can choose to answer any prayer He sees fit. But Scripture clearly indicates that God does not listen to or answer every prayer. In fact, Scripture gives the following reasons for when Prayers will not be answered regardless of who prays them.
1) Who have personal and selfish motives.
You ask and do not receive, because you ask amiss, that you may spend it on your pleasures (James 4:3).
2) Who regard iniquity in their hearts.
If I regard iniquity in my heart, The Lord will not hear (Psalm 66:18).
3) Who remain in sin.
But your iniquities have separated you from your God; And your sins have hidden His face from you, So that He will not hear (Isaiah 59:2). Now we know that God does not hear sinners; but if anyone is a worshiper of God and does His will, He hears him (John 9:31).
4) Who offer unworthy service to God.
“You are presenting defiled food upon My altar. But you say, ‘How have we defiled You?’ In that you say, ‘The table of the LORD is to be despised.’ But when you present the blind for sacrifice, is it not evil? And when you present the lame and sick, is it not evil? Why not offer it to your governor? Would he be pleased with you? Or would he receive you kindly?” says the LORD of hosts. “But now will you not entreat God’s favor, that He may be gracious to us? With such an offering on your part, will He receive any of you kindly?” says the LORD of hosts (Malachi 1:7).
5) Who forsake God.
Thus says the Lord to this people: “Thus they have loved to wander; They have not restrained their feet. Therefore the Lord does not accept them; He will remember their iniquity now, And punish their sins.” Then the Lord said to me, “Do not pray for this people, for their good. When they fast, I will not hear their cry; and when they offer burnt offering and grain offering, I will not accept them. But I will consume them by the sword, by the famine, and by the pestilence (Jeremiah 14:10-12).
6) Who reject God’s call.
Because I [Wisdom] have called and you refused, I have stretched out my hand and no one regarded, Because you disdained all my counsel, And would have none of my rebuke…. Then they will call on me, but I will not answer; They will seek me diligently, but they will not find me (Proverbs 1:24-25, 28).
7) Who will not heed God’s law.
One who turns away his ear from hearing the law, even his prayer is an abomination (Proverbs 28:9). “But they refused to heed, shrugged their shoulders, and stopped their ears so that they could not hear. Yes, they made their hearts like flint, refusing to hear the law and the words which the Lord of hosts had sent by His Spirit through the former prophets. Thus great wrath came from the Lord of hosts. Therefore it happened, that just as He proclaimed and they would not hear, so they called out and I would not listen,” says the Lord of hosts. (Zechariah 7:11-13).
8) Who turn a deaf ear to the cry of the poor.
Whoever shuts his ears to the cry of the poor, Will also cry himself and not be heard. (Proverbs 21:13).
9) Who are violent.
When you spread out your hands, I will hide My eyes from you; Even though you make many prayers, I will not hear. Your hands are full of blood (Isaiah 1:15; see also 59:2-3).
10) Who worship idols.
Therefore thus says the Lord: “Behold, I will surely bring calamity on them which they will not be able to escape; and though they cry out to Me, I will not listen to them. Then the cities of Judah and the inhabitants of Jerusalem will go and cry out to the gods to whom they offer incense, but they will not save them at all in the time of their trouble. For according to the number of your cities were your gods, O Judah; and according to the number of the streets of Jerusalem you have set up altars to that shameful thing, altars to burn incense to Baal. So do not pray for this people, or lift up a cry or prayer for them; for I will not hear them in the time that they cry out to Me because of their trouble.” (Jeremiah 11:11-14; see also Ezekiel 8:15-18).
11) Who have no faith.
But let him ask in faith, with no doubting, for he who doubts is like a wave of the sea driven and tossed by the wind. For let not that man suppose that he will receive anything from the Lord (James 1:6-7).
12) Who are living in hypocrisy.
Beware of the leaven of the Pharisees, which is hypocrisy (Luke 12:1).
13) Who are proud of heart.
God resists the proud, but gives grace to the humble (James 4:6; 1 Peter 5:5).
14) Who are self-righteous.
The Pharisee stood and prayed thus with himself, “God, I thank You that I am not like other men-extortioners, unjust, adulterers, or even as this tax collector. I fast twice a week; I give tithes of all that I possess.” And the tax collector, standing afar off, would not so much as raise his eyes to heaven, but beat his breast, saying, “God, be merciful to me a sinner!” I tell you, this man went down to his house justified rather than the other; for everyone who exalts himself will be humbled, and he who humbles himself will be exalted (Luke 18:11-14).
15) Who mistreat God’s people.
You have also given me the necks of my enemies, So that I destroyed those who hated me. They cried out, but there was none to save; Even to the Lord, but He did not answer them (Psalm 18:40-41).You who hate good and love evil; Who strip the skin from My people, And the flesh from their bones; Who also eat the flesh of My people, Flay their skin from them, Break their bones, And chop them in pieces, Like meat for the pot, Like flesh in the caldron. Then they will cry to the Lord, But He will not hear them; He will even hide His face from them at that time, Because they have been evil in their deeds (Micah 3:2-4).