The mind needs to be efficient to perform the variety of complex tasks it's faced with, and sometimes efficiency forces it to sacrifice accuracy. When that happens, we often get a cognitive bias. These biases come in many forms: they influence our perception of others, memories, beliefs, decision-making, and more. Wikipedia has a list of cognitive biases, the length of which should impress upon you just how serious a problem this is. They even have an expanded list just for memory biases.
Every aspect of our everyday use of information – gathering it, storing it, retrieving it, interpreting it, and acting on it – is subject to error. So, how should we respond to the fact that we have serious flaws in our thinking abilities? For one thing, we should be highly skeptical of the beliefs we hold – especially those with an emotional core. We should try not to let our prior attachments to those beliefs affect our search for evidence. This is why apologetics (in any religion) is inherently flawed: apologists start with a "knowledge" that their beliefs are true and look for supporting evidence, when they should instead be evaluating all evidence before reaching a conclusion.
Believers will be quick to point out that unbelievers are also subject to these biases – and they're right. While certain properties of religious belief (heritability, overemphasis on faith, wishful thinking, etc.) tend to strengthen biases in believers, in the end they do affect everyone. Ultimately, the key to conquering these mental errors is to be as honest with yourself as possible. Take the time to reflect on your biases. Consider whether you should spend more time reading and listening to opposing views. I do this occasionally, and I've found that even after I've identified my biases, it's remarkably difficult to counteract them – which just illustrates how potentially dangerous they are. If they're a problem even after finding them, imagine how much damage they're doing while they remain hidden.