Input Text blur() Method

Definition and Usage

blur() The method is used to remove the focus from a text field.

Tip:Usage focus() Method Focus can be assigned to a text field.

Example

Remove Focus from Text Field:

document.getElementById("myText").blur();

Try It Yourself

Syntax

textObject.blur()

Parameters

None.

Technical Details

Return Value:

No Return Value.

Browser Support

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
Support Support Support Support Support