Installing the YAML Form Module

  1. Copy/upload the yamlform module to the modules directory of your Drupal installation.

  2. Enable the ‘YAML Form’ module and desired sub-modules in ‘Extend’. (/admin/modules)

  3. Set up user permissions. (/admin/people/permissions#module-yamlform)

  4. Build a new form (/admin/structure/yamlform) or duplicate an existing template (/admin/structure/yamlform/templates).

  5. Publish your form as a:

    • Page: By linking to the published form. (/yamlform/contact)

    • Node: By creating a new node that references the form. (/node/add/yamlform)

    • Block: By placing a YAML Form block on your site. (/admin/structure/block)

  6. (optional) Install third party libraries.

  7. (optional) Install additional contrib modules.

Sub Modules


The YAML Form UI module provides a simple user interface for building and maintaining forms.

Unless your website is maintained by experienced Drupal developers, every website should enable the YAML Form UI module.

YAML Form Templates

The YAML Form Templates module provides starter templates that can be used to create new forms.

Besides using the provided default starter templates, you can also create custom templates for your organization.

YAML Form Node

The YAML Form Node module provides a ‘Form’ content type, which allows
forms to be integrated into a website as nodes.

The YAML Form Node module creates a form (entity reference) field that allows any form to be attached to any content type.

YAML Form Examples

The YAML Form Examples module provides examples of all available form elements and functionality. The YAML Form Examples module can used for demonstrating and testing advanced functionality or used as cut-n-paste code snippets for creating new forms.

The YAML Form Examples module allows site builders and developers to preview and experiment with working examples of all supported form elements and features.

Additional Contrib Modules

When installed, the modules below will enhance your website’s form building and submission handling functionality and experience.

YAML Form Migrate

The YAML Form Migrate provides a migration source plugin and a migration template to migrate Drupal 6 webforms to Drupal 8 YAML Forms.

YAML Form Queue

The YAML Form Queue module provides a queue handler for YAML Form, to store form submissions in a queue.


The Token module provides additional tokens not supported by core (most notably fields), as well as a UI for browsing tokens.

Tokens are supported and actively used by the YAML Form module. Installing the Token module will provide form builders with the ability to browse form and submission specific tokens.

Mail System and Swift Mailer

The Mail System module provides an Administrative UI and Developers API for managing the mail backend/plugin.

The Swift Mailer extends the basic e-mail sending functionality provided by Drupal by delegating all e-mail handling to the Swift Mailer library.

The YAML Form module provide support for HTML email. However to send file attachments, please install and configure the Mail System and Swift Mailer modules.


The Honeypot module uses both the honeypot and timestamp methods of deterring spam bots from completing forms on your Drupal site.

The Honeypot module provides the best unobtrusive protection against SPAM form submissions.


The CAPTCHA module provides the CAPTCHA API for adding challenges to arbitrary forms.

The reCAPTCHA module uses the Google reCAPTCHA web service to improve the CAPTCHA system, and to protect email addresses.

CAPTCHA provides additional, slightly obtrusive protection against SPAM submissions.

**Clientside Validation

The Clientside Validation module adds clientside validation (aka “Ajax form validation”) for all forms using jquery.validate.

The Clientside validation provides cross-browser inline validation message.


The Validators module allows you to use the Symfony Validator component within a form.

The Validators module is one of the YAML Form module’s supported validation mechanisms.

Third Party Libraries

The YAML Form module utilizes the third-party Open Source libraries listed below to enhance form elements and to provide additional functionality. It is recommended that these libraries be installed in your Drupal installations /libraries directory. If these libraries are not installed, they are automatically loaded from a CDN.

PLEASE NOTE: The Libraries API for Drupal 8 is still under development.

Currently the best way to download all the needed third party libraries is to either add yamlform.libraries.make.yml to your drush make file or execute the below drush command from the root of your Drupal installation.

drush yamlform-libraries-download

Code Mirror - Demo

A versatile text editor implemented in JavaScript for the browser.

Code Mirror is used to provide a text editor for YAML and HTML configuration settings and messages.

Geocomplete - Demo

An advanced jQuery plugin that wraps the Google Maps API’s Geocoding and Places Autocomplete services.

Geocomplete is used by the location element.

Input Mask - Demo

Input masks ensures a predefined format is entered. This can be useful for dates, numerics, phone numbers, etc…

Input masks are used to ensure predefined and custom formats for text fields.

RateIt - Demo

Rating plugin for jQuery. Fast, progressive enhancement, touch support, customizable (just swap out the images, or change some CSS), unobtrusive JavaScript (using HTML5 data-* attributes), RTL support. The Rating plugin supports as many stars as you’d like, and also any step size.

RateIt is used to provide a customizable rating form element.

Select2 - Demo

Select2 gives you a customizable select box with support for searching and tagging.

Select2 is used to improve the user experience for select menus.

Signature Pad - Demo

Signature Pad is a JavaScript library for drawing smooth signatures. It is HTML5 canvas based and uses variable width Bézier curve interpolation. It works in all modern desktop and mobile browsers and doesn’t depend on any external libraries.

Signature Pad is used to provide a signature element.

Timepicker - Demo

A lightweight, customizable javascript timepicker plugin for jQuery, inspired by Google Calendar.

Timepicker is used to provide a polyfill for HTML 5 time elements.

Toggles - Demo

Toggles is a lightweight jQuery plugin that creates easy-to-style toggle buttons.

Toggles is used to provide a toggle element.

Word and Character Counter - Demo

The jQuery word and character counter plug-in allows you to count characters or words.

Word or character counting, with server-side validation, is available for text fields and text areas.


The standard version of the CKEditor.

Allows the YAML Form module to implement a basic and simpler CKEditor.