There is no proven link between spelling and intelligence, but people often read a text with lots of spelling mistakes and make a connection anyway. There are many reasons for spelling mistakes, from tapping the wrong key to learning difficulties such as dyslexia. However, there are times when it is vital that your spelling is correct. Exams are a good example of this, but also when writing formally such as in work emails, job application letters and essays.
There are two parts to good spelling: being able to spell the words you want to spell in the first place and, more importantly, checking your spelling to make sure it is correct.
Spelling is something that you never stop learning. You will never be able to spell every single word correctly every single time, but there are ways to get better at it.