title: Getting Cookies from Headless ChromeDriver
body: <p>I am trying to use the <code>driver.Manage().Cookies.GetCookieNamed()</code> method on a headless <code>ChromeDriver</code>, but it seems to not return any cookies when the driver is in headless mode. 
  <br>Is there a way around that? 
  <br>I am trying to do some automation but I don't want to show the browser when the <code>Navigate().GoToUrl()</code> method is executed.</p>
  
  <pre><code>public static ChromeDriver NavigateDriver(string url)
  {
    var options = new ChromeOptions();
    options.AddArgument("--headless");
    options.PageLoadStrategy = PageLoadStrategy.Normal;
    var driver = new ChromeDriver(options);
    driver.Navigate().GoToUrl(url);
    return driver;
  }
  
  public static string GetCookieFromDriverInitial(ChromeDriver driver)
  {
    string cookie;
    cookie = Convert.ToString(driver.Manage().Cookies.GetCookieNamed("bm_sv"));
    return cookie;
  }
  </code></pre>