I'm only saying this from the perspective from just this thread, but nightmares and flashbacks are classic symptoms of PTSD. Dealing with those kind of symptoms is extremely difficult to do on your own, besides the fact trauma symptoms don't work anything like normal day to day stresses. Unfortunately, professional therapists really are the only option. "Home remedies" sometimes can make it worse, sometimes even reinforcing the really bad memories. At the same time, professionals who know all about PTSD know some really good techniques. And just so you know, the best PTSD treatments involve cognitive behavioral therapy, to focus your mind on different things.
What you're doing on your own right now is already off to the right track. It's important to recognize that someone else traumatized you - you may wish you left sooner, but he's the one who decided to hurt you. It helps to go out with other people. It helps to do other things than just sit around and think about what you went through. One thing you can do now is not obsess over what he did to you - whatever he did, you don't need revenge and you don't need to get back at him. If anything, a narcissist feeds off of your interaction. Cutting off contact probably truly is the worst thing you can do to him. And more than that, it gets you on track for your own life.