 <p>I'm new with WTForms but it seems to me that the solution could be improved instead of using :</p> <pre><code>{{ form.field(autofocus=true, required=true, placeholder="foo") }} </code></pre> <p>use :</p> <pre><code>{% if field.flags.required %} {{ field(autofocus=true, required=field.flags.required, placeholder="foo") }} {% else %} {{ field(autofocus=true, placeholder="foo") }} {% endif %} </code></pre> <p>WTForms seems not to handle correctly <code>required=false</code> for 100% HTML5 and sets in the HTML an attr <code>required="False"</code> instead of removing the attr. Could this be improved in next version of WTForms?</p>