# Firebase JWT Decoding issue

**URL:** <https://discourse.slimframework.com/t/firebase-jwt-decoding-issue/2909>\
**Category:** Show and Tell\
**Created:** [January 22, 2019, 10:44am UTC](https://discourse.slimframework.com/t/firebase-jwt-decoding-issue/2909 "2019-01-22T10:44:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![erickchidubem](https://avatars.discourse-cdn.com/v4/letter/e/7ea924/32.png) [@erickchidubem](https://discourse.slimframework.com/u/erickchidubem)\
**Post date:** [January 22, 2019, 10:44am UTC](https://discourse.slimframework.com/t/firebase-jwt-decoding-issue/2909/1 "2019-01-22T10:44:45Z")

</div>

$decoded = JWT::decode($jwt[‘HTTP\_AUTHORIZATION’][0], $key, array(‘JWT’,‘HS256’));

this returns an error Unexpected control character found

please help me

---

<div class="post-metadata">

**Author:** ![rbaaboud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.slimframework.com/rbaaboud/32/818_2.png) [@rbaaboud](https://discourse.slimframework.com/u/rbaaboud)\
**Post date:** [January 22, 2019, 2:34pm UTC](https://discourse.slimframework.com/t/firebase-jwt-decoding-issue/2909/2 "2019-01-22T14:34:39Z")

</div>

Can we have more details?

It seems to be a json\_decode error.

---

<div class="post-metadata">

**Author:** ![erickchidubem](https://avatars.discourse-cdn.com/v4/letter/e/7ea924/32.png) [@erickchidubem](https://discourse.slimframework.com/u/erickchidubem)\
**Post date:** [January 22, 2019, 2:36pm UTC](https://discourse.slimframework.com/t/firebase-jwt-decoding-issue/2909/3 "2019-01-22T14:36:57Z")

</div>

@rbaaboud thanks i just resolved the issue… the decode does not recognize the Bearer keyword… so i have to replace using string replace
