# Gatsby & Trailing slashes

**URL:** <https://answers.netlify.com/t/gatsby-trailing-slashes/21267>\
**Category:** Support\
**Tags:** redirects\
**Created:** [August 23, 2020, 10:10pm UTC](https://answers.netlify.com/t/gatsby-trailing-slashes/21267 "2020-08-23T22:10:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![chrism2671](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/chrism2671/32/1172_2.png) [@chrism2671](https://answers.netlify.com/u/chrism2671)\
**Post date:** [August 23, 2020, 10:10pm UTC](https://answers.netlify.com/t/gatsby-trailing-slashes/21267/1 "2020-08-23T22:10:53Z")

</div>

When I visit a page on my site:

It seems to redirect in the browser to the / version, and then remove the slash a moment later.

`https://www.wikijob.co.uk/content/interview-advice/competencies/communication`  
goes to  
`https://www.wikijob.co.uk/content/interview-advice/competencies/communication/`  
and then to  
`https://www.wikijob.co.uk/content/interview-advice/competencies/communication`

I’m not able to reproduce this on my localhost. What’s going on here?

---

<div class="post-metadata">

**Author:** ![chrism2671](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/chrism2671/32/1172_2.png) [@chrism2671](https://answers.netlify.com/u/chrism2671)\
**Post date:** [August 24, 2020, 10:22am UTC](https://answers.netlify.com/t/gatsby-trailing-slashes/21267/2 "2020-08-24T10:22:19Z")

</div>

I think I’ve fixed this issue, by disabling Netlify’s asset optimization pipeline.

---

<div class="post-metadata">

**Author:** ![jen](https://sea1.discourse-cdn.com/netlify/user_avatar/answers.netlify.com/jen/32/6044_2.png) [@jen](https://answers.netlify.com/u/jen)\
**Post date:** [August 28, 2020, 8:46pm UTC](https://answers.netlify.com/t/gatsby-trailing-slashes/21267/3 "2020-08-28T20:46:22Z")

</div>

Hey @chrism2671,  
Glad to hear this, and thanks for coming back to report your fix 🎉

I’m adding this other community post for others who may come across issues related to asset optimization and trailing slashes:

> [@Problem with assets optimization, relative links and integrity check](https://answers.netlify.com/t/problem-with-assets-optimization-relative-links-and-integrity-check/13732/10):
>
> Yup - when we optimize, we move to cloudfront, which won’t match your domain name. For most folks’ sites this isn’t a big deal, but clearly your settings are special. I use hugo with optimization myself and it’s no problem, but I use a BaseURL of / and presumably some other settings are different as well. At any rate, since we won’t be changing how we process assets in the foreseeable future, you’ll want to not use our asset optimization in case you have strict requirements about URL’s. Ther…
