# Issue with Unexpected HTML Responses Instead of JSON

**URL:** <https://openziti.discourse.group/t/issue-with-unexpected-html-responses-instead-of-json/2442>\
**Category:** Uncategorized\
**Created:** [April 15, 2024, 8:50am UTC](https://openziti.discourse.group/t/issue-with-unexpected-html-responses-instead-of-json/2442 "2024-04-15T08:50:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![softmax](https://avatars.discourse-cdn.com/v4/letter/s/e79b87/32.png) [@softmax](https://openziti.discourse.group/u/softmax)\
**Post date:** [April 15, 2024, 8:50am UTC](https://openziti.discourse.group/t/issue-with-unexpected-html-responses-instead-of-json/2442/1 "2024-04-15T08:50:47Z")

</div>

Hi everyone!

I am writing because of an issue I'm experiencing when using zrok to forward an application running locally.

The application is correctly visualized through the zrok forwarded link, but when I try to interact with it ( it is a UI to collect and query data from ML experiments [GitHub - aimhubio/aim: Aim 💫 — An easy-to-use & supercharged open-source experiment tracker.](https://github.com/aimhubio/aim)), I receive an error indicating that the data expected to be in JSON format is actually HTML. The exact error message is:

```auto
Unexpected token '<', "<html> <h"... is not valid JSON

```

This issue does not occur when accessing the application directly on the local network, where JSON responses are correctly received and parsed.

Previously, I used ngrok for the same scope and did not have this issues.

Here is also a snippet from the logs running zrok in verbose mode:

```auto
[sdk-golang/ziti/edge/network.(*edgeConn).Read: unexpected sequencer err (read timed out)]

```

Thanks in advance for any help!!

---

<div class="post-metadata">

**Author:** ![smilindave26](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/smilindave26/32/185_2.png) [@smilindave26](https://openziti.discourse.group/u/smilindave26)\
**Post date:** [April 15, 2024, 4:42pm UTC](https://openziti.discourse.group/t/issue-with-unexpected-html-responses-instead-of-json/2442/2 "2024-04-15T16:42:44Z")

</div>

Can you check the response code? HTML is returned when you receive `404 Not Found`. It might be your share is not currently available (or at a different address than you're expecting).

---

<div class="post-metadata">

**Author:** ![TheLumberjack](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/thelumberjack/32/113_2.png) [@TheLumberjack](https://openziti.discourse.group/u/TheLumberjack)\
**Post date:** [April 16, 2024, 1:08am UTC](https://openziti.discourse.group/t/issue-with-unexpected-html-responses-instead-of-json/2442/3 "2024-04-16T01:08:00Z")

</div>

Hi @softmax, welcome to the community and to zrok (and OpenZiti)!

can you share the command you used to share the service? I'm guessing/thinking you used --backend-mode web but you probably don't want that. You probably want to leave the --backend-mode empty.

Would you share the command you used?
