Hide False Spell Check Errors

You can use spellcheck="false" to prevent showing spell check errors on HTML elements.

August 27, 2019

As someone with an uncommon preferred nickname, I hate seeing those little red underlines on text that I know is correct. There are times when spell check is appropriate, and there are times when it is very unhelpful. Thankfully developers can prevent these errors by adding the spellcheck="false" attribute to their code.

<input type="text" spellcheck="false" autocorrect="false">
<textarea type="text" spellcheck="false" autocorrect="false">
<div contenteditable="true" type="text" spellcheck="false" autocorrect="false">

The most obvious use cases for this are fields with proper nouns, like names, addresses, usernames, email addresses, etc. But this can be helpful in any fields where you may get content that isn’t found in the dictionary, like for example code blocks, file names, captcha fields, and more.

This also pairs nicely (as shown above) with autocorrect="false" so that those not-really-misspelled words don’t get automatically corrected by an over-zealous computer.

See the inspiration