HTML accept-charset Attribute

The accept-charset attribute specifies the character encodings that are to be used for the form submission."

Definition and Usage

The accept-charset attribute specifies the character encodings that are to be used for the form submission.

The default value is the reserved string "UNKNOWN" (indicates that the encoding equals the encoding of the document containing the <form> element).

Applies to

The accept-charset attribute can be used on the following element:

Element Attribute
<form> accept-charset

Form Example

A form with an accept-charset attribute:

<form action="/action_page" accept-charset="ISO-8859-1">
  First name: <input type="text" name="fname"><br>
  Last name: <input type="text" name="lname"><br>
  <input type="submit" value="Submit">
</form>

Browser Support

Attribute
accept-charset Yes Yes Yes Yes Yes