This article will show you how to return members to the page they were viewing before being asked to sign up or login. This is especially handy if you have a content or functionality that is partially gated (like a blog or comment sections).
data-ms-redirect="current-url"
Use the attribute data-ms-redirect="current-url"
to save the current URL. The next time that visitor goes to sign up or login they will be returned to the page.
You can place the attribute anywhere, but we recommend placing it on your signup and login links.
Considerations
- Does not work with onboarding UI. It will override your default signup redirect.
- This will override default redirects and plan level redirects.
Keywords:
Stay on page, stay-on page, override redirect, after login, after signup, save page, save url, current url,
Comments
3 comments
This did not work for us.
Maybe a data sequencing issue?
Mark Burlinson Do you have a redirect hard-coded into your signup/login form by chance?
I just did some testing and this feature is working as expected for me. It you can share a video or read-only link that would be super helpful to debug 🙏
Please sign in to leave a comment.