Redirecting an article URL
  • 17 Oct 2022
  • 8 Minutes à lire
  • Contributeurs
  • Sombre
    Lumière
  • PDF

Redirecting an article URL

  • Sombre
    Lumière
  • PDF

There is no French content available for this article, You are viewing the fallback version (English).

You can set up an article redirect rule for any published or draft article URL. The redirect feature would come in handy when you change a specific article's URL, and the same article URL has been referenced in different articles in your knowledge base. You can also perform a bulk import of redirect rules.

Article redirect rules would prevent users from clicking on a dead link or broken link.

What are Dead links?

With context to the Knowledge base, a dead link or broken link is a hyperlink in the article that no longer works. The breakage is because the link encounters issues like URL changes, incorrect URL, page or item removed, or restricted/private knowledge base article URL. Usually, the page would load as a 404 error page.


Set up an article redirect rule

You can change the article URL or slug after or before publishing the article or category page. The index type category URL can also be altered.

You can make the changes directly on the article editor. See (changing article URL or slug).

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. You can find the list of previously added Article URL redirect rules (if any)
  3. Click New direct and a Redirect rule blade appears
  4. Select the desired redirect type
    a. Ends with: To set the redirection rule for an article
    b. Replace with: To set the redirection rule for the URL text between the domain name and article slug

Ends with

1_SreenGIF-Setting_up_article_redirect_rule

  1. Source path: Type in the URL slug you want to redirect from

The URL slug in the source path must start with a backslash.

  1. Destination path: Type in the complete destination URL (or) Type in the desired URL slug you want to redirect to

For example, you want to redirect the article URL https://docs.document360.com/docs/getting-started-with-document360 to https://docs.document360.com/docs/getting-started-video-library:

Add the source path and destination path as mentioned below:
Source path: /getting-started-with-document360
Destination path: getting-started-video-library

What is an article slug?

A slug or article slug is the part of the URL that uniquely identifies the article/page, and it's in a format that is easily readable by both users and search engines. This part comes after the "/" in your project root URL.

For example:
Article URL: https://docs.document360.com/docs/why-did-we-build-document360

Slug: /why-did-we-build-document360

  1. Click Save

Replace with

6_Screengif_settingup_article_redirect_rules_replace_with-min

  1. Source path: Type in the URL text between the domain and article slug you want to redirect from

For example, the source path in https://project.technicaldocumentation.com/v1/docs/fr/getting-started is /v1/docs/fr/

The source path must start and end with a backslash.

  1. Replace text: Type in the desired URL text you want to redirect to

For example, you can replace v1/docs/fr with v2/docs/en in the following URL https://project.technicaldocumentation.com/v1/docs/fr/getting-started

The replace text must start and end with a backslash.

  1. Click Save

Best practices

When you have a multi-lingual knowledge base, multiple versions knowledge base, or both, set redirect rules specifically for each language/version as per the requirement.

For example, when you set a redirect rule with Source path as /customer-support and Destination URL as sales-and-support, this redirect rule applies only to the main version's default language.

1. To make the above redirect rule applicable for any other language (German-de) in the main version, you must set a new redirect rule with Source path as /de/customer-support and Destination URL as de/sales-and-support
2. To make the above redirect rule applicable for the main language in an other version (v1), you must set a new redirect rule with Source path as /v1/docs/customer-support and Destination URL as v1/docs/sales-and-support
3. To make this applicable for an other language (German-de) in other version (v1), you must set a new redirect rule with Source path as /v1/docs/de/customer-support and Destination URL as v1/docs/de/sales-and-support

The other language/version refers to the language/version available in the knowledge base, excluding the main language/version.


How to set up a site redirect rule?

You can set up a subfolder redirect rule at the site level with the Replace with option on the Article redirect rules page. This option comes in handy when you migrate from another platform or want to redirect a deprecated version/language of the knowledge base.

For example, you want to set up a redirect rule for the subfolder path azure/serverless to data/clould360 in the URLs https://apidocs.serverless360.com/azure/serverless/article_slug

For more information, visit the Migrating documentation article.


Editing redirect rule

You can edit any article redirect rules anytime.

2_Screenshot-Atricle_redirect_edit

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. You can find the list of previously added Article URL redirects
  3. You can use Filter by to find the desired redirection rule
  4. Hover over the desired URL, and you can find an Edit (Pencil) icon on the right
  5. Click the Edit icon, and a blade appears on the right
  6. Update the desired field(s)
  7. Click Update

Deleting a redirect rule

You can delete any article redirect rules anytime.

4_Screenshot-Atricle_redirect_delete

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. You can find the list of previously added Article URL redirects
  3. You can use Filter by to find the desired redirection rule
  4. Hover over the desired URL, and you can find a Delete (trash bin) icon on the right
  5. Click the Delete (trash bin) icon, and a Delete confirmation prompt appears

5_Screenshot-Atricle_redirect_delete_confirmation

  1. Click Yes in the Delete confirmation prompt

You cannot retrieve the deleted article redirection rules.


Deleting multiple redirect rules

You can delete multiple redirect rules at once.

11_Screengif-Deleting_multiple_rules

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. You can find the list of previously added Article URL redirects
  3. You can use Filter by to find the desired redirection rule
  4. Hover over the desired redirect rule and select the checkbox adjacent to the desired redirect rule(s)
  5. Click the Remove button on the top

The Remove button is enabled only when you select any redirect rule.

How to delete redirect rules on multiple pages?

The pagination display is 50 redirect rules on a single page.

12_Screengif-Deleting_multiple_rules_pagination

  1. Click the Select all button, and the 50 records available on that page will be selected.
  2. If you wish to choose multiple other page records, navigate to the desired page(s) and click the Select all button

When you navigate to the other page(s), if you double-click the Select all button, only the 50 records available on that particular page are selected. All the selections you have done on the other page(s) will go off.

The count of the selected redirect rules appears at the bottom right as Number of rules selected.

  1. Click the Remove button at the top

Filter by

10_Screenshot-Filters_redirect_rules

a. Search: Type in the keyword of the source path or destination URL in the Search field, and the result is populated

b. Modified date: You can filter the redirect rules with their last modified date.
* Choose from any default date ranges such as 1 year, 3 months, 30 days, and 7 days.
* If you want to choose a custom date range, click Select specific dates and select the desired date range
* Click Clear to clear the date range selection and display all the redirect rules

c. Type: You can filter the redirect rules with the redirect type. Click the Type dropdown and choose the desired redirect type
* Ends with: Displays only Ends with redirect type
* Replace with: Displays only Replace with redirect type
* Both: Displays both Ends with and Replace with redirect types

d. Clear filters: Click the Clear filters icon next to the Type dropdown to clear the applied filters and display all the redirect rules


Sorting redirect rules

  • Click the column header to sort the columns available on the redirect rule page
  • The upward and downward arrows available next to the column header show the sorting type

Importing redirect rules

You can import bulk redirect rules at once by uploading a CSV that matches the following template.

Source Destination RedirectionType
/myoldarticle newarticle endswith
/en/customers/ /v1/docs/ replacewith
The file size should be less than or equal to 1MB.

(or)

Import redirect rule file template

You can also download the template here:

import-redirect-rule.csv

Once the redirect rule data has been added to the downloaded template file, save it in your local storage.

7_Screenshot-Import_redirect_rules_1

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. Click the Import redirect rule at the top right
  3. An Import redirect rules blade appears on the right
  4. Either drag and drop the CSV file from the local storage onto the designated dropbox
    (or)
    Choose the Click here to choose a file option and select the CSV file using the device's file explorer.
The file size should be less than or equal to 1MB.

8_Screenshot-Import_redirect_rules_2

  1. The CSV is uploaded, and the data in the file is validated
  2. The following pieces of information are displayed before proceeding with the import
    a. Valid rule(s)
    b. Invalid rule(s)
    You can download the invalid rule(s) list by clicking the Download icon next to the invalid rule(s) count.

If you don't want to import the redirect rules:

  • Click Cancel
  • All the data retrieved from the CSV file are removed
  1. Click Import to import the valid link(s)
  2. Wait for a few seconds, and the number of redirect rules imported appears

Redirect rule limits

How many redirect rules can I set up in a project?

You can set up a maximum of 10000 redirect rules per project. If you exceed the limit, please contact our support team.

Is there any limitation for the import redirect rule option?

  • You can import a maximum of 1000 redirect rules per day in a project
  • You can use the import redirect rules option a maximum of five times per day
  • If you exceed the limit, please contact our support team.

By default, the structure of the article URL appears in the below format
https://subdomain.domain.tld/docs/article_slug
However, the article URL still works when it contains article or doc instead of docs as the URL path between the domain and article slug.

For example, all the below three URLs will fine work.

  1. https://docs.document360.com/docs/customization-editor
  2. https://docs.document360.com/doc/customization-editor
  3. https://docs.document360.com/article/customization-editor

https://docs.document360.com/article/customization-editor and https://docs.document360.com/doc/customization-editor will be redirected to https://docs.document360.com/docs/customization-editor


Exporting redirect rules

The redirect rule(s) can be exported as a CSV file.

9_Screenshot-Export_redirect_rules

  1. From the knowledge base portal, go to SettingsKnowledge base siteArticle redirect rules
  2. Click the Export CSV at the top right
  3. The CSV file is generated and downloaded to your local storage
  4. This file can be viewed on any application for spreadsheets like Microsoft Excel and others

Cet article vous a-t-il été utile ?