---
title: "Comment by Sergiy Voznyak on \"Enabling Chrome Extension Logging with Datadog: A Journey of Trial and Error\" | Hashnode"
description: "Hi Guy! Thank you very much for sharing your experience. Did you face a CORS error while sending logs to DD from the extension? I have a problem: all requests,"
url: "https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae/comment/654d4ec5779490033fc411d2"
---

[Discussion](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae)

Comment [Enabling Chrome Extension Logging with Datadog: A Journey of Trial and Error](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae)

[Sergiy Voznyak](https://hashnode.com/@SergioV85)

[Nov 9, 2023](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae/comment/654d4ec5779490033fc411d2)

Hi Guy! Thank you very much for sharing your experience. Did you face a CORS error while sending logs to DD from the extension? I have a problem: all requests, either from `background` or `content` are rejected by Datadog with the error:

```
Access to fetch at 'http-intake.logs.datadoghq.eu/api/v2/logs' from origin 'chrome-extension://*********' has been blocked by CORS policy: Request header field dd-api-key is not allowed by Access-Control-Allow-Headers in preflight response.
```

Postman's exact (absolutely the same) request passed successfully (code 202 and entry in Datadog).

[Guy Goldenberg](https://hashnode.com/@gripguyg)

[Nov 28, 2023](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae/comment/654d4ec5779490033fc411d2#reply-6565e0843f1e344797233d45)

Interesting! Generally, since the API should be accessible and must receive this header, I suspect this might be related to the endpoint you are trying to send the logs to.

I see that you are using `http-intake.logs.datadoghq.eu/api/v2/logs`

It's worth trying to send the requests to `[http-intake.logs.datadoghq.com/api/v2/logs](https://http-intake.logs.datadoghq.com/api/v2/logs)` (`.com` instead of `.eu`)

Let me know if it works :)

[Yuki Oshima](https://hashnode.com/@maco)

[Mar 21, 2024](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae/comment/654d4ec5779490033fc411d2#reply-65fbceeeea7df4785ec5ffb2)

Hi. I'm facing a similar error as well. I think this behavior might be because the API is not designed to be called from a browser. I would be grateful if you could let me know if you find any workarounds.

[Sargis](https://hashnode.com/@Sarkis)

[Jun 26, 2024](https://hashnode.com/posts/enabling-chrome-extension-logging-with-datadog-a-journey-of-trial-and-error/64be67cbdff7801f7f82e1ae/comment/654d4ec5779490033fc411d2#reply-667c5cce745ad85767532098)

[Guy Goldenberg](https://hashnode.com/@gripguyg)

Unfortunately, I am also facing same issue. Works in postman, getting CORs issue from background script:

```
Access to fetch at 'http-intake.logs.us5.datadoghq.com/api/v2/logs' from origin 'chrome-extension://obdlkagmmgblbmgmflmkeopiennejpph' has been blocked by CORS policy: Request header field dd-api-key is not allowed by Access-Control-Allow-Headers in preflight response.
```
