French and Spanish are similar in that they are both varieties of vulgar Latin, and therefore share many grammatical characteristics, but the similarities generally end there. I have learnt both at the same time, and whilst at first I mixed them up, I have since managed to easily separate them in my brain (so that I no longer get confused).
The funny thing is, when I started to learn Japanese, the same thing happened with Japanese (i.e. I started mixing it with Spanish and French). So, in my opinion it's not that French and Spanish are similar which causes you to mix them up and get confused, it is probably that you are simply learning two languages at the same time. The exact same thing would probably happen regardless of which languages you were studying. The good news is, however, that you can train your brain to better distinguish between the languages you are studying and to not get confused all the time. I managed it with several languages, although I'm not really sure how I did it.