Back to RoR Development posts

Choosing an app hosting platform using the Analytic Hierarchy Process (AHP)

Dec 2022

Choosing the right application hosting platform is critical for any organisation that needs to host a web application. The choice of platform will directly impact your applications’ performance, reliability, and security. With so many options available, how can you be sure you’re making the best decision for your company?

This was a recent problem facing one of our clients; they used a custom CloudFoundry Platform as a Service (PaaS) to host their Ruby on Rails applications. The platform was being decommissioned, and we needed to recommend an alternative hosting provider.

One tool that can help make this decision easier is the Analytic Hierarchy Process (AHP). AHP is a multiple-criteria decision analysis method for comparing and ranking options based on multiple criteria. In this post, we’ll walk through how we used AHP to choose an application hosting platform that met their needs.

The AHP is a structured method for organizing and analyzing complex decisions. It was developed in the 1970s by Thomas L. Saaty, a professor of decision sciences at the University of Pittsburgh.

Deciding on your decision criteria and weights

A few steps are involved in using AHP. First, you’ll need to identify your decision criteria. These are the factors that will influence your decision-making process. For example, the decision criteria we used for choosing for new hosting platform included cost, features, ease of migration, and security.

If you’re doing this with multiple stakeholders, getting a group consensus on the criteria is essential; otherwise, the outcome may not suggest the best option for everyone.

Once you have your criteria, you’ll need to assign weights to each one. This is done by comparing each criterion in pairs and rating them on a scale of 1-9 (1 being not important and 9 being very important).

Because AHP uses pair-wise decision-making, you want to keep the number of criteria below ten; otherwise, the process can take a long time, and the quality of the results diminishes. For example, we assume the performance is compatible across the hosting platforms (if we scale the application to similar CPU/Memory), so we didn’t include it as a criterion.

Once we identified the decision criteria, we needed to assign weights to each criterion. This is to help prioritise the importance of each factor in the final recommendation.

A table showing the criteria and their respective weights.
An example of the results of ranking the decision criteria to generate their respective weights using AHP.

You can use the free tool AHP-OS to help calculate the weights and then complete the AHP process.

Shortlisting hosting platforms as a service (PaaS)

For the hosting options (called alternatives in AHP), we had a shortlist of:

  • Heroku
  • Google Cloud Platform (GCP) Cloud Run
  • Amazon Web Services (AWS) Co-pilot
  • Microsoft Azure K8

We originally had to on the shortlist, but as the client was a government client, it would have been too difficult to procure without it being the GCloud framework.

As CloudFoundry uses buildpacks for its containers, we only considered options that could deploy buildpacks or factored in the time to convert the buildpack into a Docker container image under the ease of migration criterion.

Evaluated options against the criteria

With the alternatives (hosting options) selected and the weights assigned to each category, we were ready to compare the hosting options. We used AHP-OS to generate a comparison matrix and rank the alternatives based on our earlier identified criteria.

This part of the process requires expert knowledge; some rankings are easier to determine, like cost, while others are more subjective, either based on our experience deploying to these platforms in the past or reviewing the features listed on the platforms’ developer documentation.

Once completed, you will get a percentage-based result of how each alternative compares to the other. Using this information, we could determine that the best hosting platform for our client was AWS Co-pilot, closely followed by GCP Cloud Run.

A table showing the final outcome of the AHP process, with each alternatives respective weights
An example of the completed AHP process with the recommendations for each alternative.


Choosing an application hosting platform is no small task – there are many factors to consider, and choosing one that will meet your specific needs is important.

The Analytic Hierarchy Process (AHP) is a powerful tool for comparing and ranking multiple options based on multiple criteria.

We used AHP to decide on a suitable alternative PaaS hosting platform for our client to host their Ruby on Rails application as the CloudFoundry PaaS they were using was being decommissioned. Using decision criteria and assigning weights to each, we could easily compare the alternatives and determine that AWS Co-pilot was the best choice for them.

AHP is one model for decision-making; you could use additional models in conjunction with AHP, for example, the Technique for Order of Preference by Similarity to Ideal Solution (TOPSIS), Best Worst Method (BWM) or Ordinal Priority Approach (OPA), to validate if the recommendation was correct. AHP might not be the best model for extremely complex scenarios, which cannot be broken down, or where the criteria are hard to identify.

Stay up to date with our blog posts

Keep up-to-date with our latest blog posts, news, case studies, and thought leadership.

  • This field is for validation purposes and should be left unchanged.

We’ll never share your information with anyone else. Read our Privacy Policy.