# Attribute “validate” not allowed on element “form” at this point.

> Canonical HTML version: https://rocketvalidator.com/html-validation/attribute-validate-not-allowed-on-element-form-at-this-point
> Attribution: Rocket Validator (https://rocketvalidator.com)
> License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/)

HTML forms have built-in constraint validation that is **enabled by default**. When a user submits a form, the browser automatically checks inputs against their constraints (such as `required`, `type="email"`, `pattern`, `min`, `max`, etc.) and prevents submission if any validation fails. There is no need to add a `validate` attribute to opt into this behavior because it is the default.

The HTML specification defines `novalidate` as a valid boolean attribute on the `<form>` element to *disable* this default validation, but it does not define a corresponding `validate` attribute. Using `validate` will trigger a W3C validation error because the browser doesn't recognize it and will simply ignore it.

This matters for several reasons:

- **Standards compliance**: Invalid attributes make your HTML non-conforming, which can cause issues with automated testing and quality tools.
- **Developer confusion**: A `validate` attribute suggests it's doing something functional, but it has no effect. Future maintainers may incorrectly believe it's enabling validation and be reluctant to remove it.
- **Accessibility and tooling**: Screen readers and other assistive technologies rely on well-formed HTML. Unrecognized attributes can lead to unpredictable behavior in some user agents.

To fix this issue, determine your intent:

1. **If you want form validation enabled** — simply remove the `validate` attribute. Validation is on by default.
2. **If you want form validation disabled** — replace `validate` with `novalidate`.

## Examples

### Incorrect: using the invalid `validate` attribute

```html
<form validate action="/submit">
  <label for="email">Email:</label>
  <input type="email" id="email" name="email" required>
  <button type="submit">Submit</button>
</form>
```

This triggers the error: **Attribute "validate" not allowed on element "form" at this point.**

### Correct: relying on default validation (attribute removed)

Since constraint validation is enabled by default, simply remove the invalid attribute:

```html
<form action="/submit">
  <label for="email">Email:</label>
  <input type="email" id="email" name="email" required>
  <button type="submit">Submit</button>
</form>
```

The browser will automatically validate the `email` input — checking both the `required` constraint and that the value matches a valid email format — before allowing submission.

### Correct: using `novalidate` to disable validation

If your intention is to disable built-in validation (for example, because you handle validation with JavaScript), use the `novalidate` attribute instead:

```html
<form novalidate action="/submit">
  <label for="city">City:</label>
  <input type="text" id="city" name="city" required>
  <button type="submit">Submit</button>
</form>
```

In this example, even though the input has the `required` attribute, the browser will **not** prevent form submission when the field is empty, because `novalidate` tells the browser to skip constraint validation on submission.

### Using `formnovalidate` on a specific button

If you want validation enabled for normal submission but want to bypass it for a specific button (such as a "Save Draft" button), use the `formnovalidate` attribute on that button instead of disabling validation for the entire form:

```html
<form action="/submit">
  <label for="name">Name:</label>
  <input type="text" id="name" name="name" required>
  <button type="submit">Submit</button>
  <button type="submit" formnovalidate formaction="/save-draft">Save Draft</button>
</form>
```

The "Submit" button will enforce validation, while the "Save Draft" button will skip it. This approach gives you fine-grained control without needing an invalid attribute.
