Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

HTML | accept-charset Attribute

  • Difficulty Level : Basic
  • Last Updated : 19 Jul, 2019

The accept-charset attribute is used to define the character encoding and is used for form submission. The default value of the accept-charset attribute is “UNKNOWN” string which indicates the encoding equals to the encoding of the document containing the <form> element.


Attention reader! Don’t stop learning now. Get hold of all the important HTML concepts with the Web Design for Beginners | HTML  course.

<form accept-charset = "character_set">

Attribute Value: The attribute value contains the list separated value of one or more encoding attributes. The common value of encoding attribute is: UTF-8, ISO-8859-1. This attribute always associated with the form element only.


<!DOCTYPE html>
        <title>accept-charset attribute</title>
            h1 {
            body {
        <h2>accept-charset Attribute</h2>
        <form action="#" accept-charset="UTF-8">
            First name:<input type = "text" name = "fname">
            Last name:<input type = "text" name = "lname">
            <input type="submit" value="Submit">


Supported Browsers: The browser supported by accept-charset attribute are listed below:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera
  • Apple Safari

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!