Support the ongoing development of Laravel.io →
Requests Packages

I am unable to use Guzzle with external, publicly accessible websites (ie. Google.com) from my local environment. Anytime I try to use a public website with Guzzle I receive the following error:

cURL error 6: Couldn't resolve host 'www.google.com' (see http://curl.haxx.se/libcurl/c/libcurl-errors.html)

  • I am able to use Guzzle with other local sites on my machine (ie. test.dev).
  • I am able to browse to Google.com in my browser.
  • I am able to curl Google.com from the command line.
  • I am able to exec('curl http://www.google.com') from my application.

I've been banging my head with this and need some help. Anyone have any ideas?

I'm running Apache 2.4 & PHP 5.6 on my local mac (Snow Leopard).

Last updated 3 years ago.
0

Sign in to participate in this thread!

Eventy

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.