Documentation
Feedback
Guides
Troubleshooting

Troubleshooting
Store performance
My routes are not behaving as expected

Troubleshooting steps for issues with routes.

Keywords: Routes | Redirects | GraphQL

If the store redirect path doesn't work and the routes are not behaving as expected, follow these troubleshooting steps.

Solution

Checking if the redirect is saved in the Rewriter

  1. Install the GraphQL IDE in your account by running vtex install vtex.admin-graphql-ide@3.x.
  2. Access the Admin and go to Store Settings > Storefront > GraphQL IDE.
  3. Select the vtex.rewriter@1.x app from the dropdown list.
  4. Run the following query, replacing {URL} with the from path you're having trouble with:

_10
{
_10
redirect {
_10
get(path: "/{URL}") {
_10
from
_10
to
_10
}
_10
}
_10
}

The expected response is a JSON object containing all the redirects related to that path, as in the following example:


_10
{
_10
"data": {
_10
"redirect": {
_10
"get": {
_10
"from": "/about-us",
_10
"to": "/my-store"
_10
}
_10
}
_10
}
_10
}

If the query doesn't return the redirect path

Access the Admin, go to Storefront > Pages > Redirects, and save the desired URL redirects. For more information, check the Managing URL redirects guide.

If the query returns the redirect path

Check if your Store Theme or another app has defined a route with the same path you are attempting to save as a redirect. If the route already exists, the redirect will be ignored.

Contributors
1
Photo of the contributor
Was this helpful?
Yes
No
Suggest Edits (GitHub)
Contributors
1
Photo of the contributor
On this page