# Problem configuring Redirect

**URL:** <https://forum.ghost.org/t/problem-configuring-redirect/39826>\
**Category:** Using Ghost\
**Created:** [July 13, 2023, 12:43pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826 "2023-07-13T12:43:30Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 12:43pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/1 "2023-07-13T12:43:31Z")

</div>

I am trying to setup a redirect.

I downloaded the redirect.json. It took me a while to figure out that the documentation was for a redirect.yaml and not the default .json file.

Now that I got that figured out I created a .yaml file with a single redirect

301:  
/blog/privacy: /blog/privacypolicy

and it does not work.

---

<div class="post-metadata">

**Author:** ![Cathy\_Sarisky](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/cathy_sarisky/32/25750_2.png) [@Cathy\_Sarisky](https://forum.ghost.org/u/Cathy_Sarisky)\
**Post date:** [July 13, 2023, 1:58pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/2 "2023-07-13T13:58:26Z")

</div>

Hey max1e6! Welcome to Ghost!

.yaml is really fussy about spacing. Do you have the two spaces before /blog… ? In the future, if you use the `</>` button in the editor menu, your code and markup will show up in more readable form. :)

Did you upload the yaml file with a .yaml extension? (Not .json.) I’m not sure if Ghost cares, but it might.

And could you say what you mean by ‘does not work’? Endless redirect loop, or no redirect at all?

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 3:44pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/3 "2023-07-13T15:44:28Z")

</div>

Thanks for the reply!

Yes, I did use the .yaml extension.

Yes, Ghost does care. If you use a .json extension I appears to parse it like a .json file same same for .yaml.

I did double check for two spaces before /blog.

Does not work…no redirect at all.

---

<div class="post-metadata">

**Author:** ![Cathy\_Sarisky](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/cathy_sarisky/32/25750_2.png) [@Cathy\_Sarisky](https://forum.ghost.org/u/Cathy_Sarisky)\
**Post date:** [July 13, 2023, 4:35pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/4 "2023-07-13T16:35:03Z")

</div>

Let me check one more thing.

You uploaded the redirects.yaml to Ghost using Settings \> Labs, right? You didn’t just put it into the theme or try to find a copy in the actual Ghost install and edit it, right?

If you haven’t already done so, restarting Ghost (if self-hosted) is worth trying.

(Sorry for asking silly questions, but I get lucky and identify the problem with the silly question often enough that I keep doing it.)

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 5:25pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/5 "2023-07-13T17:25:21Z")

</div>

Yep. Uploaded in Labs-\>Redirects.

There is no such thing as a silly question.

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 5:28pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/6 "2023-07-13T17:28:05Z")

</div>

Just restarted. Still does not redirect. 404.

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 5:35pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/7 "2023-07-13T17:35:38Z")

</div>

I even upgrade ghost to the latest version (just now). Still 404.

---

<div class="post-metadata">

**Author:** ![RyanF](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/ryanf/32/17448_2.png) [@RyanF](https://forum.ghost.org/u/RyanF)\
**Post date:** [July 13, 2023, 5:45pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/8 "2023-07-13T17:45:33Z")

</div>

Are you able to share your site where this is happening? It might help to diagnose. I tested this redirect on my own site and it worked for me, so I think something else might be going on.

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 6:05pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/9 "2023-07-13T18:05:18Z")

</div>

[www.williammax.com/blog/privacy](http://www.williammax.com/blog/privacy)

---

<div class="post-metadata">

**Author:** ![max1e6](https://sea1.discourse-cdn.com/flex015/user_avatar/forum.ghost.org/max1e6/32/25396_2.png) [@max1e6](https://forum.ghost.org/u/max1e6)\
**Post date:** [July 13, 2023, 6:26pm UTC](https://forum.ghost.org/t/problem-configuring-redirect/39826/10 "2023-07-13T18:26:37Z")

</div>

Thanks Ryan.

I think I might know what is going on and I have not figured out a solution.

I am self hosting ghost on docker using Traefik as a reverse proxy.

The site is [IT Trends & DevOps by William Max & Co.](https://www.williammax.com/blog), but the docker container thinks it is [https://www.williammax.com](https://www.williammax.com).

I am using Traefiks “strippprefix” to strip the /blog from the URL before sending to the docker container.

According to one article I found on the Internets…the stripprefix occurs before the redirect. I tried modifying the redirect to /privacy → /privacypolicy, but this did not work either.
