After all is always two words.
- After all, 15 minutes of exercise is better than nothing.
- Things weren’t so bad, after all. I was among friends again
- We’ve decided not to go away after all.
While afterall is not a word. (See also: After all vs After all is said and done )