Using content type fields within page.html.twig
In the preprocess_page set up the variable 

if (($node = \Drupal::routeMatch()-&gt;getParameter('node')) &amp;&amp; $node instanceof \Drupal\node\NodeInterface) {
 $variables['bg_color'] = $node-&gt;field_header_color-&gt;value;      


}
     and use this in ur twig file

&lt;header id="header" class="header" role="banner" aria-label="{{ 'Site header'|t }}" style='background-color:{{bg_color}}'&gt;