# Redirecting the old forum urls to the discourse

**URL:** <https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228>\
**Category:** Product Support\
**Tags:** unsupported-install\
**Created:** [September 7, 2020, 7:51am UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228 "2020-09-07T07:51:56Z")\
**Posts on this page:** 19\
**Page:** 1

## AI-generated summary

A user is trying to redirect old WordPress forum URLs (e.g., `example.com/question/questioncontent`) to new Discourse topics (`example.com/t/questioncontent`) after migration. Despite using the permalinks feature in Discourse admin settings, redirects are not working. The community clarifies that permalinks only handle incoming external links, not internal links within Discourse. For internal links, manual updates or a plugin like [discourse-articles](https://github.com/paviliondev/discourse-articles) are suggested. The user is confused about how to configure redirects and whether multiple URLs can be added. [pfaffman](/t/-/163228/2) explains the correct setup, while [fzngagan](/t/-/163228/5) provides code to modify the plugin for redirects. [Stephen](/t/-/163228/11) and [pfaffman](/t/-/163228/12) confirm that permalinks work for inbound links but not internal ones, and [Vamshi_Krishna](/t/-/163228/13) seeks clarification on the correct approach for a smooth migration.

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 7, 2020, 7:51am UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/1 "2020-09-07T07:51:56Z")

</div>

I am trying to migrate from WordPress based forum to Discourse .

My old url is like this

`https://example.com/question/questioncontent`

And in discourse I see topics are created with uri

`https://example.com/t/questioncontent`

So I copied entire content from my old forum to new forum  
Im not that techy so I don’t wanted to take risk I have about 18 posts so I didn’t went with any scripts . I copied all the content manually.

Now my question is how can I redirect  
My old forum links which are already indexed in search engines.

I tried permalink feature to redirect , but still I am not able to redirect

Did I missed something? Anywhere please guide me with the correct procedure

---

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [September 7, 2020, 2:45pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/2 "2020-09-07T14:45:06Z")

</div>

See admin → customize → permalinks. You can create a redirect from the 18 old URLs to their new topics.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 7, 2020, 5:07pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/3 "2020-09-07T17:07:45Z")

</div>

I tried unfortunately they are not redirected

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 12:10pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/4 "2020-09-10T12:10:40Z")

</div>

Any help? This is not working for me

---

<div class="post-metadata">

**Author:** ![fzngagan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fzngagan/32/259349_2.png) [@fzngagan](https://meta.discourse.org/u/fzngagan)\
**Post date:** [September 10, 2020, 12:32pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/5 "2020-09-10T12:32:48Z")

</div>

I have written a plugin to do so.

> **[GitHub - paviliondev/discourse-articles](https://github.com/paviliondev/discourse-articles)**
>
> Contribute to paviliondev/discourse-articles development by creating an account on GitHub.

> <https://github.com/paviliondev/discourse-articles/blob/8a79f4eeff6399cfe1cbbd738a847080c8e8fef2/plugin.rb#L17>

Change the above to:  
` get '/question/:slug', to: redirect('/t/%{slug}')`

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 12:36pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/6 "2020-09-10T12:36:25Z")

</div>

Thanks will try and let u know

---

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [September 10, 2020, 2:54pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/7 "2020-09-10T14:54:00Z")

</div>

I cannot imagine why not, but it’s impossible to tell without more information about what you did. I cannot imagine why you’d need a plug-in, though. For 18 you can just create them by hand, though you could possibly use a permalink normalization to do them all at once.

Edit: permalink works only for incoming links, not links within discourse. What is usually done is to rewrite those links in the posts.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 3:45pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/8 "2020-09-10T15:45:09Z")

</div>

I was redirecting my old forum urls to discourse one. Dont know why its not working for me.

i wanted to confirm  
suppose my old url is 1. [forum.example.com/must-read-rules](http://forum.example.com/must-read-rules)  
and discourse one is 2. [forum.example.com/t/must-read-rules/47](http://forum.example.com/t/must-read-rules/47)

i have to enter this 1. in New field and 2 in destination field am i right?

Sry for dumb question!

---

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [September 10, 2020, 3:55pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/9 "2020-09-10T15:55:07Z")

</div>

You’d enter `must-read-rules` in the URL field , leave the “topic ID” selected, and put 47 in the topic ID field. Like this:

![image](https://global.discourse-cdn.com/meta/original/3X/f/1/f1e0b39e867f6afb849a1ab36dc959f5ac6240f1.png)

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 12:27pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/10 "2020-09-10T12:27:50Z")

</div>

The redirect option under customize option is not working for me.

How can I make it work?

---

<div class="post-metadata">

**Author:** ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)\
**Post date:** [September 10, 2020, 1:24pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/11 "2020-09-10T13:24:19Z")

</div>

Are you trying to use it to redirect inbound links _to_ discourse content, or to redirect links within discourse (i.e between pages).

---

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [September 10, 2020, 2:57pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/12 "2020-09-10T14:57:11Z")

</div>

Right! Permalink works only for incoming URLs. I bet this is the problem.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 3:40pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/13 "2020-09-10T15:40:40Z")

</div>

@pfaffman @Stephen Im migrating from wordpress to discourse. I m redirecting my old urls to discourse generated urls.

ex: [forum.example.com/question/hey](http://forum.example.com/question/hey) to [forum.example.com/t/hey](http://forum.example.com/t/hey)

---

<div class="post-metadata">

**Author:** ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)\
**Post date:** [September 10, 2020, 3:43pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/14 "2020-09-10T15:43:59Z")

</div>

Inbound links will be redirected by the permalinks feature. Internal links **between** posts will need to be corrected to reflect their new destination, permalink redirection won’t work there.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 3:47pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/15 "2020-09-10T15:47:11Z")

</div>

What are the possible ways to make it work?  
the first url was my previous wordpress forum one and second url is my discourse one  
How can i redirect successfully.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 4:44pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/16 "2020-09-10T16:44:28Z")

</div>

Can u please tell me how can i edit the code any guide? i installed the plugin but i didnt found specific area which u are referring to edit the slug?

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 10, 2020, 4:58pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/17 "2020-09-10T16:58:28Z")

</div>

Tried unfortunately not working 😔

---

<div class="post-metadata">

**Author:** ![fzngagan](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/fzngagan/32/259349_2.png) [@fzngagan](https://meta.discourse.org/u/fzngagan)\
**Post date:** [September 10, 2020, 5:48pm UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/18 "2020-09-10T17:48:44Z")

</div>

You’ll have to fork the plugin.

---

<div class="post-metadata">

**Author:** ![Vamshi\_Krishna](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vamshi_krishna/32/192455_2.png) [@Vamshi\_Krishna](https://meta.discourse.org/u/Vamshi_Krishna)\
**Post date:** [September 11, 2020, 1:03am UTC](https://meta.discourse.org/t/redirecting-the-old-forum-urls-to-the-discourse/163228/19 "2020-09-11T01:03:35Z")

</div>

Can I add multiple urls there?  
Or only structure of url?
