When using BrowserStack Local, I encountered the ‘self signed certificate in certificate chain‘ error. What should I do?

This error occurs when you have SSL inspection enabled in your network. To resolve this issue, take one of the following actions:

  • Work with your network administrator to allow traffic to the *.browserstack.com domain to bypass SSL inspection.
  • Disable SSL inspection entirely for BrowserStack Local connections.
  • Pass the root CA certificate to the BrowserStack Local, if you are on windows.
    • In browserstack.yml, set the certificate as shown below:
      browserstackLocal: true
      browserStackLocalOptions:
        --use-ca-certificate: <PEM_file_abs_path>
    • Or, set it via CLI when starting the Local binary, as shown below:
      ./BrowserStackLocal --key <access_key> --force-local --use-ca-certificate <PEM_file_abs_path>
  • Pass the system-installed certificate to the BrowserStack Local, if you are on macOS or Linux.
    • In browserstack.yml, set the certificate as shown below:
      browserstackLocal: true
      browserStackLocalOptions:
      --use-system-installed-ca
    • Or, set it via CLI when starting the Local binary, as shown below:
      ./BrowserStackLocal --key <access_key> --force-local --use-system-installed-ca

For more information, see Setting up Local with SSL Inspection in Network in BrowserStack documentation. To see the list of flags you can use with BrowserStack Local, see Flags for Local Binary.

Other Resources

Still can’t find what you are looking for?

We are always happy to help with any questions

Support resources Contact Us