Add captcha to webform I'm working on a drupal 8 project, I've created a webform and trying to associate a captcha to my webform using captcha contrib module.
I've a personalized template for my webform in which I render the webform fields.
I've associate the captcha to the webform under /admin/config/people/captcha/captcha-points and test as anonymous user it is always unable to associate captcha to the webform.


Should I print captcha in my webform template file? if so how to do it?
Should I add an element Captcha to my webform fields? if so is that element by default use captcha contrib module settings?


Any help is appreciate.
To captcha protect a webform you NEED to add a captcha element to it. When captcha contrib module is enabled on your site the available captcha challenge types are available to be used on a per webform basis.

The template twig file is mostly for design puproses. 

If the placement of captcha within the form is not to your liking you should copy the default webform template from /modules/contrib/webform/webform.html.twig to your theme /themes/custom/MYTHEME/templates/webform--WEBFORM_MACHINE_NAME.html.twig and perhaps place each element seperately.

The default webform.html.twig is

&lt;form{{ attributes }}&gt;
  {{ title_prefix }}
  {{ children }}
  {{ title_suffix }}
&lt;/form&gt;


And in our own copy we should take out {{ children }} and replace with individual elements but also we have to make sure form ids and actions are included manually and it the final template should end up looking similar to this 

&lt;form{{ attributes }}&gt;
  {{ title_prefix }}
  {{ element.elements.first_name }}
  {{ element.elements.last_name }}
  {{ element.elements.captcha }}

  {# necessary elements #}
  {{ element.form_build_id }}
  {{ element.form_id }}
  {{ element.actions }}

  {{ title_suffix }}
&lt;/form&gt;


Where captcha for example is the machine name of the captcha field