CURL error 28 while downloading Connection timed out after 10000 milliseconds

Stefan Izdrail

Founder & Senior Architect · 2026-06-29

Laravel Company
Title: Resolving CURL Errors During Laravel Package Installations: A Comprehensive Guide Introduction: In the world of web development, using Laravel and its ecosystem of packages is an essential skill for any developer. However, sometimes issues may arise during package installation, such as this specific CURL error 28 in conjunction with a "Connection timed out after 10000 milliseconds" message. This blog post will provide developers with a comprehensive understanding of the issue and steps to address it effectively. Body: 1. Understanding the Issue: When you encounter the CURL error 28 during Laravel package installation, it represents a general problem related to your network connection or server-side issues. The "Connection timed out after 10000 milliseconds" message indicates that the download process has failed due to poor network connectivity or an overloaded server. 2. Troubleshooting Steps: To resolve this issue, you can follow these steps: - Check your internet connection: Ensure that you have a stable and fast internet connection. If you're working on a localhost environment, try changing your network settings or reconfigure your DNS server to improve connectivity. - Analyze the package URL: Verify the URL of the package you are trying to install (e.g., https://repo.packagist.org/packages.json) for any typos or outdated links. If you're unsure, go directly to the package on Packagist (https://laravel-collective.github.io/LaravelYajraDataTables/) and download it manually before trying to install via Composer. - Reboot your system: Sometimes, a simple reboot of your system can clear any temporary network issues or connection problems that could be affecting the installation process. 3. Enabling Composer Cache: By default, Composer utilizes caching mechanisms to speed up package downloads and reduce potential errors. However, if caching has become corrupted or is causing the issue, you may need to clear it. Follow these steps to do so: - Edit your composer configuration file (located in ~/.composer/config.json) and add the line "disable-tls" under the "options" section. This will disable TLS checking for better compatibility with older packages or servers. { "platform": { "installers": [] }, "repositories": [], "scripts": {}, "config": { "disable-tls": true } } - Run the command `composer self-update --disable-tls` to update Composer with the new configuration. 4. Using a VPN or Proxy: If your network is restricting outbound access to certain websites, using a Virtual Private Network (VPN) or proxy can help circumvent these restrictions and ensure proper downloads. Connect to a reliable VPN service or set up a SSH tunnel before attempting the installation once more. 5. Consulting Package Documentation: If none of the above solutions work for you, check the official package documentation for further troubleshooting tips related specifically to your issue. Sometimes, package authors include helpful hints and alternative methods of downloading or installing their product. Conclusion: While CURL errors may appear daunting at first, following these steps systematically can help identify the root cause and provide solutions. Remember that persistence and patience are key in such situations, as you may need to try multiple approaches before finding the one that works best for your specific circumstances. If you're still unable to resolve the issue, consider reaching out to the package author or the Laravel community for support. At https://laravelcompany.com/, we prioritize providing high-quality Laravel services and guidance to help developers overcome challenges like these efficiently.