How to get a variable from FieldWidget in the same modules Template
You already pass the template variable sign_src to your template. Now you want to pass an additional variable. You can easily do this by extending your hook_theme implementation:

/**
 * Implements hook_theme().
 */
function signature_theme() {
  $theme = [];
  $theme['signature'] = [
    'render element' =&gt; 'element',
    'variables' =&gt; [
      'sign_src' =&gt; NULL,
      'text_area_id' =&gt; NULL,
    ],
  ];
  return $theme;
}


Then pass the ID into your template like this:

$value = $items[$delta]-&gt;value ?: '';
$text_area_id = 'signature_field_' . $items-&gt;getName();

$file_upload_help = [
  '#theme' =&gt; 'signature',
  '#sign_src' =&gt; $value,
  '#text_area_id' =&gt; $text_area_id,
];


And use it in your template like this:

{{ text_area_id }}


Edit: Some further suggestions for your code snippets:

Wherever possible, you should leave rendering to the theming engine and avoid manually calling the \Drupal::service('renderer')-&gt;renderPlain() method. Your description will do just fine with the render array. Your #suffix can be changed to a distinct child element of your widget element (note: there is no hash before):

$element['#description'] = $file_upload_help;
$element['suffix'] = $sign_thumb;


In your template, you can change the empty check to

{% if sign_src %}
  &lt;img src="{{sign_src}}" class="sign-img" /&gt;
{% endif %}


And should wrap the src URL into quotes.

A final note about the URL itself: It seems to be a user given value. If so, consider using UrlHelper::stripDangerousProtocols before you pass it into the template.