This is not easily answered. Dreams have three sources. The first source is the rumination of your heart regarding your life. The second is demonic influence and the third are dreams that come from God. The first source is the majority of our dreams.
A nightmare could derive from both the rumination of your heart and demonic influence. Fear is based upon belief. Unbelief and fear go hand in hand. Unbelief is belief in anything contrary to the Word of God. Satan is the father of lies. All lies are twisting of truth. Truth must be present in a lie or the lie will not be believed. Satan understands how to take small fears and turn them into bigger fears.
Fear is a godly thing. It is the emotion of caution and carefulness. It becomes ungodly when it paralyzes us or motivates us to make hasty decisions and take foolish actions.
Dreams are symbolic language of the heart. If the symbolism is misunderstood, confusion can be created. Dreams are not made for conscious comprehension, although we are able to consciously comprehend them. Dreams are communications of the spirit to the heart, which is why spirits can touch us in our dreams, whether they be God or demons.
Not knowing your nightmares, all I can suggest is that you stand in your authority in Christ. We are told:
2Co 10:3 For though we walk in the flesh, we do not war after the flesh:
2Co 10:4 (For the weapons of our warfare are not carnal, but mighty through God to the pulling down of strong holds
2Co 10:5 Casting down imaginations, and every high thing that exalteth itself against the knowledge of God, and bringing into captivity every thought to the obedience of Christ;
2Co 10:6 And having in a readiness to revenge all disobedience, when your obedience is fulfilled.
Controlling our thought life is the heart of Christian discipleship. Review the nightmares and verbally cast them out of your mind. Verbally declare the truth of the Scriptures of who you are in Christ and the promises of God that apply to you in Christ. Monitor the meditations of your heart. What do you think about all day? Those thoughts will become part of your dream life, too. If you think of fearful things, that fear will be in your dreams. If you think of the blessings you have Christ, those thoughts will also be in your dreams.