Skip to main content

What is routing?

This series of articles shows you how to implement routing on a Contensis published application where routing isn't natively supported.


These articles assume that you have some basic knowledge of programming concepts such as functions, methods, and classes.

It also assumes you have some familiarity with developing in Contensis using our Delivery API and Razor views.

Routing overview

When building applications, routing refers to defining a set of URLs to render content that isn't tied to a physical page/file, such as entries created using content types in Contensis.

You may have seen URLs like this:, where the query string parameter is used to determine which movie to render. Usually this is achieved by matching the ID to a record in a database to return and display the content.

URLs formatted in this way make sense to developers, but not to users or search engines. Ideally, your application should use human-readable URLs. These allow users and search engines to navigate your application effectively and more easily understand your content.

Why routing?

Clean URLs make it easier for people to know where they are within your application and if they want they can navigate by adding or removing parts of the URL.

Human readable URLs help search engines to tell users what your content relates to. Even if the title tag is missing or not well written, for example. Search engines can always return relevant information about your content and help people get to it quickly.

There is also a benefit in a social media/sharing context. URLs that give users more information on what the content being shared is about make people more likely to click on a link.

Clean URLs

Implementing routing cleans up your URL, so this: 

Becomes this: 

Routing also gives you the flexibility to implement URLs that group a collection of content together. In the case of movies, this could be by release date:{year}/{month}

Or, by genre:{genre}

You can then link to a specific piece of content by adding a unique identifier, usually the title of the content, to the URL e.g:{genre}/{movie-title}.

In this example, an actual URL might look like this:

When implementing routing, we strongly recommend that you consider user experience, the effect on SEO, and any documented information architecture.