Support the ongoing development of Laravel.io →
moderator

Hello @davidbenjaminndundu-collab

That sounds frustrating, it looks like your installation of wamp is incorrect or at least does not have the correct settings or certificates to have a successful ssl connection.

Maybe you can check the installation docs to see what can be changed to fix it.

0

Step 1: Confirm your PHP path

Open Command Prompt (CMD) and run: php -i | find "Loaded Configuration File"

Make sure it points to the same PHP you’re using in WAMP: C:\wamp64\bin\php\php8.1.0\php.ini

Step 2: Download the latest cacert.pem

Your SSL certificate bundle is outdated, let’s get the latest one.

  1. Go to this official source: https://curl.se/ca/cacert.pem

  2. Save the file as cacert.pem

  3. Place it in: C:\wamp64\bin\php\php8.1.0\extras\ssl\cacert.pem (If the extras\ssl folder doesn’t exist, you can create it.)

Step 3: Configure PHP to use the new certificate

Open your php.ini file (found in the path from step 1), and look for the line: ;curl.cainfo =

Uncomment it and set it to your path: curl.cainfo = "C:\wamp64\bin\php\php8.1.0\extras\ssl\cacert.pem" openssl.cafile = "C:\wamp64\bin\php\php8.1.0\extras\ssl\cacert.pem" Make sure to use backslashes () and the correct PHP version folder.

Step 4: Restart everything

  1. Close all CMD/PowerShell windows

  2. Restart WAMP (or restart the Apache + PHP services)

  3. Open a new CMD window and check: php -r "print_r(openssl_get_cert_locations());" It should show your new cacert.pem path.

Step 5: Re-run Composer installation

Now run the Composer installer again: php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" php composer-setup.php php -r "unlink('composer-setup.php');" If everything is correct, it should install successfully without the SSL error.

Step 6 (Optional): Add Composer to PATH

Move composer.phar to a global location: move composer.phar C:\composer\composer.phar

Then add this to your system PATH: C:\composer\

And test: composer -V

0

Sign in to participate in this thread!

Native PHP

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.