> ## Content Index
> Fetch the complete content index at: https://www.blog.nestict.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# 🛠 Updating Ghost Routes and Redirects: A Step-by-Step Upgrade Guide
- URL: https://www.blog.nestict.com/updating-ghost-routes-and-redirects-a-step-by-step-upgrade-guide/
- Published: 2025-11-01T16:49:57.000Z
- Updated: 2025-11-01T17:52:03.000Z
- Author: Nestict Infotech CSR
- Tags: seo, Featured

At **NESTICT INFOTECH**, we’re continuously enhancing our digital systems to deliver structured, optimized, and reliable web experiences. One of our latest improvements involves upgrading our **Ghost blog routing and permalink structure** — to make content URLs more organized, SEO-friendly, and consistent across all posts.

---

### 🧭 Why Update Routes?

By default, Ghost uses simple post URLs like:

```
https://www.nestict.com/my-post/

```

While that’s clean, it doesn’t reflect when the post was created or published.  
To improve chronological navigation and SEO clarity, we implemented a **date-based permalink format** that includes the year, month, and day:

```
https://www.nestict.com/20251101/my-post/

```

This makes your content easier to organize, archive, and interpret by both readers and search engines.

---

### ⚙️ Updating `routes.json`

We modified the Ghost routing configuration to include date tokens in the permalink.  
The new structure is defined as follows:

```json
{
  "routes": {},
  "collections": {
    "/": {
      "permalink": "/{year}{month}{day}/{slug}/",
      "template": ["index"]
    }
  },
  "taxonomies": {
    "tag": "/tag/{slug}/",
    "author": "/u/{slug}/"
  }
}

```

#### 🔍 What This Does:

- Uses `{year}{month}{day}` to automatically insert the publish date.
- Keeps the `{slug}` for post readability.
- Updates author URLs to a cleaner `/u/{slug}/` format.
- Maintains all tag pages under `/tag/`.

Once uploaded via **Ghost Admin → Settings → Labs → Routes**, Ghost will start applying the new URL pattern immediately.

---

### 🔁 Adding Redirects to Avoid 404s

Whenever URL structures change, it’s critical to handle redirections properly to prevent broken links.  
We prepared a **redirects.json** file to ensure that old links continue to work seamlessly.

Example:

```json
[
  {
    "from": "^/author/(.*)/?$",
    "to": "/u/$1/",
    "permanent": true
  },
  {
    "from": "^/u/(.*)$",
    "to": "/u/$1/",
    "permanent": true
  },
  {
    "from": "^/writers/(.*)/?$",
    "to": "/u/$1/",
    "permanent": false
  },
  {
    "from": "^/users/(.*)/?$",
    "to": "/u/$1/",
    "permanent": false
  },
  {
    "from": "^/profile/(.*)/?$",
    "to": "/u/$1/",
    "permanent": false
  },
  {
    "from": "^/([^/]+)/?$",
    "to": "/:year:month:day/$1/",
    "permanent": true
  }
]
```

You can upload this file under:

```
Ghost Admin → Settings → Labs → Redirects → Upload redirects.json

```

Once uploaded, Ghost immediately activates the redirects, ensuring a smooth transition without affecting SEO.

---

### 🧩 Key Notes

- Ghost supports `{year}`, `{month}`, `{day}`, `{slug}`, `{primary_tag}`, and `{primary_author}` in permalinks.
- Tokens like `{id}` or `{hour}` are **not supported** natively.
- For time-based (HHMM) or ID-style URLs, automation via **n8n** or **custom API scripts** can rename slugs dynamically during post publishing.

---

### 🚀 Outcome

With this update:

- All blog posts now follow a standardized, date-based permalink structure.
- Older links remain functional via smart redirects.
- The blog is more structured, readable, and SEO-compliant.

This ensures visitors always reach the right content — and search engines better understand your publishing timeline.

---

### 💬 Final Thoughts

Routing and redirection may sound technical, but they’re essential for a smooth reader experience and long-term SEO health.  
At **NESTICT INFOTECH**, we’re proud to implement these refinements across our platforms — ensuring every click leads exactly where it should.

---

📘 *Need help configuring your own Ghost routes or redirects?*  
Reach out to our technical team via [support.nestict.com](https://selfcare.nestict.africa/?ref=blog.nestict.com) or drop us a message — we’ll be glad to assist.

---