Do all rules have an exception? It seems so. I have learnt this little riddle some twenty years ago (yes, twenty!) from an amazing English language teacher. Her name was Kerri, she worked as an air-hostess for British Airways in Paris and was studying for her DELTA in my language school for a career change.
Here is how it works, the little spelling bird told me, the rule is 'I' before 'E' hence we spell believe, fierce, friend. But receive, deceit, receipt etc. go the other way around as this is after 'C'.
Of course there are some exceptions, otherwise this would be too easy, such as species, science, sufficient or seize, vein, weird, their, feisty, foreign - but you can use this rule whenever you are unsure how to spell a word especially if the phonic sound that ie or ei form is a long ee sound.