# Attempting to renew session - 'origin\_mismatch'

**URL:** <https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320>\
**Category:** Get Help\
**Tags:** renew\
**Created:** [January 29, 2018, 4:09pm UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320 "2018-01-29T16:09:30Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![grantfeldman](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/grantfeldman/32/7568_2.png) [@grantfeldman](https://community.auth0.com/u/grantfeldman)\
**Post date:** [January 29, 2018, 4:09pm UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/1 "2018-01-29T16:09:30Z")

</div>

This has only started happening in the last few days. No code changes at all

```
The redirectUri's origin (http://localhost) should match the window's origin (http://localhost:4200).

    private renewToken() {
        this.auth0.checkSession({}, (err, result) => {
            if (err) {
                throw err;
            }
            this.setSession(result);
        });
    }

```

---

<div class="post-metadata">

**Author:** ![lawjolla](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/lawjolla/32/29463_2.png) [@lawjolla](https://community.auth0.com/u/lawjolla)\
**Post date:** [January 30, 2018, 5:29am UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/2 "2018-01-30T05:29:14Z")

</div>

Same problem. It doesn’t appear that `auth0` ignores `redirectUri`

---

<div class="post-metadata">

**Author:** ![lawjolla](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/lawjolla/32/29463_2.png) [@lawjolla](https://community.auth0.com/u/lawjolla)\
**Post date:** [January 30, 2018, 5:38am UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/3 "2018-01-30T05:38:07Z")

</div>

The lastest version of auth0-js (9.1.3 and 9.1.2) parses the port off localhost, so `redirectUri:"http://localhost:4200"` becomes `http://localhost`  
I pinned my release to 9.1.0 and everything now works fine.  
Pretty poor testing guys…

Fix merged here [9.1.2: Error with redirectUri origin · Issue #640 · auth0/auth0.js · GitHub](https://github.com/auth0/auth0.js/issues/640)

---

<div class="post-metadata">

**Author:** ![lawjolla](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/lawjolla/32/29463_2.png) [@lawjolla](https://community.auth0.com/u/lawjolla)\
**Post date:** [January 30, 2018, 5:39am UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/4 "2018-01-30T05:39:05Z")

</div>

[https://github.com/auth0/auth0.js/issues/640](https://github.com/auth0/auth0.js/issues/640)

---

<div class="post-metadata">

**Author:** ![simon.schmitt](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@simon.schmitt](https://community.auth0.com/u/simon.schmitt)\
**Post date:** [February 22, 2018, 8:33pm UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/5 "2018-02-22T20:33:07Z")

</div>

This PR 640 add port to url in IE and Auth0 recognizes a mismatch

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [August 13, 2019, 2:35pm UTC](https://community.auth0.com/t/attempting-to-renew-session-origin-mismatch/9320/6 "2019-08-13T14:35:31Z")

</div>


