Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Rretzko's avatar

Vapor login hitting cUrl error

Hi - After a have dozen existing projects with staging and production environments. I'm trying to initialize a new environment in Vapor but get the following error from

vapor login

after entering my email address and password:

In CurlFactory.php line 276:
                                                                                                                                                                                   
  cURL error 60: SSL certificate problem: unable to get local issuer certificate (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://vapor.laravel.com/api/login                                                                                                                                                                               

The new env is vanilla Laravel 12. I don't recall hitting this error in any of my earlier environments. Any help with interpreting what I need to do is appreciated! Rick

0 likes
2 replies
LaryAI's avatar
LaryAI
AI
Best Answer
Level 58

Certainly! The error you’re seeing:

cURL error 60: SSL certificate problem: unable to get local issuer certificate

means that your local machine cannot verify the SSL certificate for the Vapor API because it’s missing the necessary CA certificates.

This is a common PHP/cURL issue, especially on fresh setups or after OS updates.

Here’s how you can fix it:


1. Download the latest CA certificates


2. Tell PHP/cURL where to find the certificate

On Windows:

  1. Save cacert.pem somewhere (e.g., C:\cacert.pem).

  2. Open your php.ini file (find its location with php --ini).

  3. Find (or add) this line:

    curl.cainfo = "C:\cacert.pem"
    
  4. Also, set for OpenSSL (optional but recommended):

    openssl.cafile = "C:\cacert.pem"
    
  5. Save the file and restart your terminal or web server.


On macOS/Linux:

  • Most systems already have CA certificates, but if not, you can install them:

    • macOS (with Homebrew):

      brew install ca-certificates
      
    • Ubuntu/Debian:

      sudo apt-get update
      sudo apt-get install ca-certificates
      
  • If you downloaded cacert.pem, point your php.ini to it:

    curl.cainfo = "/full/path/to/cacert.pem"
    openssl.cafile = "/full/path/to/cacert.pem"
    

3. Verify

After making these changes, restart your terminal or web server and try:

vapor login

It should now work without the cURL error.


Summary:
This is a local environment issue, not a Laravel or Vapor bug. It’s about your PHP/cURL setup missing the CA certificates needed to verify SSL connections.

If you still have issues, let me know your OS and PHP version for more specific steps!

Please or to participate in this conversation.