Matthew 18:19 Again I say to you, if two of you agree on earth about anything they ask, it will be done for them by my Father in heaven. 20 For where two or three are gathered in my name, there am I among them."
As with all scripture, the broader context must be sought to accurately gain the meaning of Jesus' words. In John 15:7 Jesus taught concerning prayer, "If you abide in Me and My words abide in you, ask whatever you wish and it will be given to you." John instructs us that we abide in Jesus by obeying (keeping) His word (1 John 3:24). John also clarifies what "whatever" is that Jesus was speaking of in John 15:7. The "whatever" is anything according to God's will (1 John 5:14-15).
Matthew 18:19-20 is referring to anything we ask according to God's will. We have a very powerful opportunity in prayer if we know God's will. How do we know God's will? The written word is the record of God's will. If we are to know God's will, then we need to know the Bible. If we are to get to know the Bible, we need to read it consistently and entirely. We need to read it depending on the Holy Spirit to teach us (John 14:26; 1 Corinthians 2:12).
We also need to be listening to the Spirit of God to help us know what to pray (Romans 8:26). We are to listen to what the Holy Spirit instructs us as Philip did in Acts 8:26-40. Read the Acts passage and note in verse 29 how the Holy Spirit gave Philip a specific command. The command did not contradict the written word of God. A communication to us by the Holy Spirit will never contradict the written word. Some things in life we find difficult determining the will of God. One area is the area of physical healing. The written word teaches us that all who believe will have a perfect body when Jesus comes again, but is not that clear concerning physical healing. We need to have the Holy Spirit come upon us with power to have answered prayer concerning physical healing.
We know for certain it is God's will for us to understand His word, to live an abundant life, to have our daily needs met, to be free from the habits of sin. We need to pray together and see God work powerfully in our lives and the lives of the people we pray for. Let's test the boundaries of Matthew 18:19-20 by finding a likeminded person and praying together to see God's good, pleasing and perfect will accomplished in the lives of the people we pray for. I have access to a likeminded person in my own house, my wife. We pray together to secure God's unlimited provision in peoples' lives. Find a likeminded person and begin to pray together.