jQuery Form Events

Beginner
⏱️ Hub guide
📚 Updated: Jul 2026
🚀 14 event tutorials

What You’ll Learn

Form events let JavaScript respond when users interact with inputs, textareas, selects, and other focusable elements. jQuery’s .on() and .off() provide a consistent API. Start with the blur event — the most common pattern for field-level validation.

01

.on()

Bind handlers

02

blur

Lose focus

03

focus

Gain focus

04

.trigger()

Fire events

05

focusout

Delegation

06

14 guides

Full index

Introduction

Every signup form, login page, and search box relies on knowing when a user enters or leaves a field. Form events cover those moments — plus value changes and form submission. jQuery wraps the browser’s native event system so you write one handler that works everywhere.

What Are jQuery Form Events?

Form events are named strings passed to .on()"blur", "focus", "change", "submit", and others. The handler receives an event object with details about the interaction. Unlike deprecated shortcuts like .blur(fn), .on("blur", fn) is the modern approach that also supports delegation and namespaced unbinding.

💡
Beginner Tip

Use .on("blur", handler) to validate or clean up a field when the user tabs away or clicks elsewhere. Pair with .on("focus", handler) to show hints when they enter the field.

📝 Syntax

Minimal blur binding workflow:

jQuery
$("#email").on("blur", function() {
  // validate when user leaves the field
});
$("#email").trigger("blur");
$("#signup-form").on("focusout", "input", function() {
  // one handler for all inputs — bubbles
});

👀 blur vs focus vs focusout vs deprecated .blur()

Four related focus APIs — pick the right tool:

.on("blur", fn) → modern bind — fires when element loses focus .on("focus", fn) → opposite — fires when element gains focus .on("focusout", fn) → bubbles — one handler on parent form .blur(fn) → deprecated shorthand — use .on("blur") instead

Form Event Tutorial Index

Search by event name or browse by category. Each tutorial includes syntax, try-it examples, and FAQs.

Focus & Blur

8 tutorials

React when form fields and other elements gain or lose keyboard focus.

EventDescriptionTutorial
focus eventBind a handler or trigger the focus event when an element gains focus — click in, tab to, or call .trigger('focus').Open
focusin eventBubbling focus event — bind on parent forms to react when any nested input gains focus, including dynamic fields.Open
.focus()Deprecated shorthand to bind or trigger focus — use .on('focus') and .trigger('focus') in new code (since 3.3).Open
.focusin()Deprecated shorthand to bind or trigger focusin — use .on('focusin') and .trigger('focusin') in new code (since 3.3).Open
blur eventBind a handler or trigger the blur event when an element loses focus — tab away, click elsewhere, or call .trigger('blur').Open
focusout eventBubbling blur event — bind on parent forms to validate or react when any nested input loses focus, including dynamic fields.Open
.focusout()Deprecated shorthand to bind or trigger focusout — use .on('focusout') and .trigger('focusout') in new code (since 3.3).Open
.blur()Deprecated shorthand to bind or trigger blur — use .on('blur') and .trigger('blur') in new code (since 3.3).Open

Value Changes

2 tutorials

Respond when the user commits a new value in inputs, selects, and textareas.

EventDescriptionTutorial
change eventBind a handler or trigger the change event when an input, select, or textarea value changes — immediate on select/checkbox, on blur for text inputs.Open
.change()Deprecated shorthand to bind or trigger change — use .on('change') and .trigger('change') in new code (since 3.3).Open

Text Selection

2 tutorials

React when the user highlights text inside inputs and textareas.

EventDescriptionTutorial
select eventBind a handler when the user highlights text inside an input or textarea — not the HTML select dropdown.Open
.select()Deprecated shorthand to bind or trigger select — use .on('select') and .trigger('select') in new code (since 3.3).Open

Form Submission

2 tutorials

Intercept form submit attempts for validation, AJAX, or conditional send.

EventDescriptionTutorial
submit eventBind a handler when the user attempts to submit a form — validate, preventDefault, or send with AJAX before navigation.Open
.submit()Deprecated shorthand to bind or trigger submit — use .on('submit') and .trigger('submit') in new code (since 3.3).Open

Conclusion

jQuery form events turn field interactions into JavaScript callbacks. Start with .on("blur", handler) for validation when users leave inputs, use .on("focus", handler) to show hints on entry, and reach for focusout delegation when forms grow dynamically.

❓ Frequently Asked Questions

Form events respond to user interaction with form controls and other focusable elements — blur when focus leaves a field, focus when it enters, change when a value is committed, submit when a form is sent, and others. jQuery binds them uniformly with .on() and .off().
Use $('#email').on('blur', function(event) { ... }) since jQuery 1.7. The old .blur(handler) shorthand is deprecated. For parent-level handlers on dynamic forms, use focusout or delegated .on('blur', 'input', fn).
blur fires whenever an element loses focus — even if the value did not change. change fires only when the value actually changed and the element loses focus (for text inputs) or immediately (for checkboxes and selects). Use blur for validation UI; use change when you only care about new values.
Call $('#field').trigger('blur') to run bound blur handlers. Useful before form submit to validate the field the user is still typing in.
Native blur does not bubble. jQuery maps blur to focusout in delegation methods since 1.4.2, so .on('blur', 'input', fn) on a form works. Alternatively, bind .on('focusout', 'input', fn) directly.
Read the overview, study the blur vs focus comparison, browse the event index, then open the blur event tutorial for full syntax, five try-it labs, and event-specific FAQs.

Start with blur event

Learn .on("blur"), .trigger("blur"), and form validation patterns.

blur event tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

6 people found this page helpful