title: How to resolve "Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource"
body: <p>I am trying to make a fetch request for my React app, but I keep getting this CORS error. The request works fine in Postman. I have added the Access-Control-Allow-Origin header. I also tried adding mode: 'no-cors', but that did not work either. I can't find anything online for any other solutions. This is the code I'm using:</p>
  
  <pre><code>    var myHeaders = new Headers();
      myHeaders.append("Authorization", "Bearer &lt;MY_API_KEY&gt;");
      myHeaders.append("Cookie", "__cfduid=db290300ecfe95ec1fe3bc92c388c3c991586618117");
      myHeaders.append("Access-Control-Allow-Origin", "*");
  
      var requestOptions = {
      method: 'GET',
      headers: myHeaders,
      redirect: 'follow'
      };
  
      fetch("https://api.yelp.com/v3/businesses/search?location=Houston", requestOptions)
      .then(response =&gt; response.text())
      .then(result =&gt; console.log(result))
      .catch(error =&gt; console.log('error', error));
  </code></pre>