Want to display the validation error message above the webform
you can put the validation messages above the webform by -



1.put the generic element above the form

messages:
  '#type': status_messages


2.make sure the webform's status messages purge all messages using the below hook in a CUSTOM_MODULE

function CUSTOM_MODULE_webform_element_alter(array &amp;$element, \Drupal\Core\Form\FormStateInterface $form_state, array $context) {
  if (isset($element['#type']) &amp;&amp; $element['#type'] === 'status_messages') {
    $element['#pre_render'][] = 'CUSTOM_MODULE_webform_element_status_messages_pre_render';
  }
}

/**
 * Pre render callback to display status messages element.
 */
function CUSTOM_MODULE_webform_element_status_messages_pre_render($element) {
  // Replace the status messages placeholder with the rendered messages.
  // Calling drupal_get_messages(NULL, TRUE) will purge all messages, which 
  // prevent the messages block from being displayed.
  // @see \Drupal\Core\Render\Element\StatusMessages
  // @see drupal_get_messages()
  $element = [
    '#theme' =&gt; 'status_messages',
    '#message_list' =&gt; drupal_get_messages(NULL, TRUE),
    '#status_headings' =&gt; [
      'status' =&gt; t('Status message'),
      'error' =&gt; t('Error message'),
      'warning' =&gt; t('Warning message'),
    ],
  ];
  return $element;
}