From App Service Plans to Azure Container Apps: Reducing Costs by 99%

Transforming our infrastructure with Azure Container Apps
1. Introduction: Context and Initial Challenge
As a software engineer and project leader in Adevinta's Information Systems department, we realized we were wasting a significant amount of money on computing resources that were barely used. Our original architecture in Azure was based on App Service Plans, a common solution, but in our case, it had become an economic and operational burden.
We managed a variety of applications, each with specific requirements. To accommodate these needs, we had implemented a complex architecture with different types of App Service Plans: simple plans for applications without special requirements, plans associated with App Service Environments (ASE) for those that needed a fixed outbound IP, and segregated plans for Linux and Windows applications. This fragmentation, while responding to initial needs, generated complex and inefficient management.

App service plans architecture
I conducted an exhaustive analysis of the actual usage of our applications during the last month and the results were shocking. I discovered that, on average, 99% of our applications were only active during 5% of the day. Despite this extremely low utilization, we were religiously paying 3,000 euros per month for computing resources that remained idle most of the time.

Usage of one of our most used app
I decided we needed a radical change. The need was even more pressing given that we were immersed in a major "splitting" project, where we had to multiply our entire current infrastructure by four. This exponential growth, had we maintained the previous architecture, would have quadrupled our already high costs, making the project economically unfeasible. Cost optimization wasn't just desirable; it was essential!
2. Problems with App Service Plans-Based Architecture (The "Why" of the Change)
Our App Service Plans-based architecture, although initially functional, was causing several critical problems:
Exorbitant Costs
The main headache was, without a doubt, the cost. Paying €3,000 per month for resources that were used intermittently was unacceptable. We were assuming significant economic waste due to a pricing model based on constant resource reservation, rather than actual consumption.
"Backside Effects": The Unwanted Neighbor Effect
We experienced the dreaded "backside effects." When one of our applications, due to a one-time demand spike, consumed most of the resources of its App Service Plan, the other applications hosted in the same plan were directly affected. This resulted in performance degradation, instability, and an inconsistent user experience.
Inefficient and Costly Scaling
Scaling was another weak point. If a single application within an App Service Plan needed to scale to handle increased traffic, the entire App Service Plan would scale, even for applications that didn't require it. This "block" scaling was not only inefficient in terms of resources but also further drove up our costs.
Management Complexity
Managing multiple App Service Plans of different types, with their specific configurations, had become a complex and laborious task. This consumed valuable team time and increased the risk of configuration errors.
It was clear that we needed a solution that would allow us to optimize costs, improve scalability, and simplify the management of our infrastructure. We were looking for a more modern, efficient architecture adapted to our applications' usage characteristics.
3. Azure Container Apps: The Solution (The "How" They Did It)
After evaluating various alternatives, the answer to our problems came from Azure Container Apps. This platform, based on Kubernetes and serverless technology, presented itself as the ideal solution for our specific use case. Why Azure Container Apps? Because of its key features that directly solved our main concerns:
- Consumption Model: Pay Only for What You Use: Azure Container Apps operates under a consumption model. We only pay for the CPU and memory resources that our applications actually use, and only during the time they are active. This eliminated the problem of fixed costs for resource reservation at its root, allowing us to achieve drastic savings.
- Automatic and Precise Scaling: The platform automatically scales each Container App individually according to demand. If an application needs more resources, Container Apps scales it granularly, without affecting other applications and without unnecessarily scaling the entire infrastructure. This guaranteed us efficient and cost-optimized scalability.
- Total Application Isolation: Each Container App runs in its own isolated environment. This completely eliminated "backside effects." The performance of one application would no longer be affected by another's resource consumption, ensuring a consistent experience for each user.
- Radical Architecture Simplification: With Azure Container Apps, we were able to consolidate all our applications in a single Azure Container Environment. Goodbye to the complexity of managing multiple App Service Plans. A simpler architecture, easier to manage and maintain.
- Homogenization of CI/CD and Dockerization: Azure Container Apps requires applications to run in Docker containers. This requirement prompted us to adopt Dockerization across our entire application portfolio. While this involved an initial adaptation effort, the result has been a complete homogenization of our CI/CD. Previously, we managed different CI/CD pipelines for webapps and functions. Now, thanks to containerization, we have a single unified CI/CD process for all our applications.
4. The Migration Process: Step by Step and Dual Environment (Pre and Pro)
I designed a gradual and planned migration process, App Service Plan by App Service Plan. This strategy allowed us to minimize risks, validate each step of the process, and ensure a smooth transition.
Dual Environment
We created a "Pre" environment identical to production to validate the migration.
Exhaustive Testing
We validated performance, stability, and functionality in the pre-production environment.
Gradual Migration
We implemented the migration in production, App Service Plan by App Service Plan.
A key piece of the strategy was the implementation of duplicate Pre-production (Pre) and Production (Pro) environments. We created a "Pre" environment completely identical to our current production environment. In this "Pre" environment, we conducted exhaustive tests of the migration to Azure Container Apps, validating the functionality, performance, and stability of the migrated applications without affecting our production services at all.
Once the tests in "Pre" were passed and with the confidence of a validated process, we proceeded to replicate the migration in our Production "Pro" environment. This approach provided us with security and control throughout the migration process.
It is important to highlight that we have not yet completed 50% of the total migration. We are migrating App Service Plan by App Service Plan, but even at this early stage, the results are already extraordinary.
5. The New Architecture with Azure Container Apps (The "Result")

The simplified architecture with Azure Container Apps
The new architecture based on Azure Container Apps is radically simpler and more efficient. We've gone from a constellation of App Service Plans to a single Azure Container Environment that hosts all our containerized applications.
This simplification translates into:
- Centralized Management: Managing a single environment instead of multiple fragmented plans drastically reduces operational complexity.
- Unified Visibility: Having all applications in the same environment facilitates monitoring, tracking, and general infrastructure management.
- Less Maintenance: A simpler architecture means fewer components to maintain, reducing effort and the risk of errors.
6. Tangible Results and Benefits: 99%+ Savings, Expansion Viability, and Homogenized CI/CD!
Spectacular savings
The results have exceeded our most optimistic expectations. We've achieved cost savings of over 99%. We went from paying €3,000 per month to just €30 monthly. In our "splitting" project, these savings become colossal: from €12,000 to only €120 monthly.
The results of the migration to Azure Container Apps have exceeded our most optimistic expectations. The most impressive fact, and now even more relevant given our "splitting" project, is the cost savings of over 99%. We've gone from paying €3,000 per month for our current infrastructure to a fraction of that amount, approximately €30 monthly. But if we consider the expansion that involves multiplying our infrastructure by four, the savings become colossal.
In a "splitting" scenario with the previous architecture, our projected monthly costs would have skyrocketed to 12,000 euros (4 times the initial €3,000). With Azure Container Apps, even with the infrastructure quadrupled, we maintain a minimal cost, estimated at less than €120 monthly. This massive saving, which exceeds €11,800 per month, not only directly impacts our budget but also makes our expansion project economically viable. The migration to Azure Container Apps has been fundamental to ensuring the scalability of our infrastructure without compromising the financial sustainability of our growth.
In addition to the savings and simplification, we've obtained significant benefits in our development processes:
Homogenized and Improved CI/CD
Dockerization, driven by the migration to Azure Container Apps, has allowed us to radically unify and simplify our CI/CD. We now manage a single CI/CD pipeline for all our applications, regardless of whether they are webapps or functions. This homogenization greatly simplifies deployment management and reduces the operational complexity for our development teams.
Efficient Versioning and Rollbacks
We implemented a versioning system for our repositories within the CI/CD. This provides us with complete traceability of the code deployed in each version of each application. If needed, we can perform rollbacks to previous versions quickly, simply, and with total security. This version control has significantly improved our ability to respond to potential problems and the overall stability of our applications in production.
7. Lessons Learned and Next Steps
The migration to Azure Container Apps has been a resounding success and a key strategic decision for the future of our infrastructure. One of the biggest learnings has been understanding the importance of planning cloud architecture not only for current needs but also anticipating future growth scenarios like our "splitting" project. Although the migration initially focused on immediate cost optimization, it has proven to be an even more valuable investment by preparing us for expansion.
We've also learned the value of robust and homogenized CI/CD, especially in containerized architectures. The migration to Azure Container Apps prompted us to improve our CI/CD processes, and this improvement in the development flow has become a very important additional benefit. If we were to start over, we would dedicate even more time to the planning and testing phase in the "Pre" environment to further refine the migration strategy and document each step for future migrations.
Our next step is to complete the migration of 100% of our App Service Plans to Azure Container Apps. We are also exploring other advanced features of the platform, such as auto-scaling based on custom metrics and integration with other Azure services, to continue optimizing our infrastructure and improving the user experience.
8. Conclusion: The Future is Container Apps
In this project that I led and managed, Azure Container Apps has completely transformed our infrastructure in Azure. We've achieved spectacular cost savings of over 99%, a radical simplification of architecture, a significant improvement in the performance and scalability of our applications, a homogenized and efficient CI/CD, and most importantly, we've made our ambitious infrastructure expansion viable.
For B2B companies with intermittent usage patterns like ours, and for any company looking to optimize costs, improve development processes, and prepare for growth, Azure Container Apps has become the ideal platform for building modern, efficient, scalable, cost-effective, and agile cloud infrastructure.
If you're looking for a solution to the same challenges, we strongly recommend exploring Azure Container Apps!
This project has demonstrated the enormous potential of Azure Container Apps to optimize costs and scale cloud infrastructures, as well as to modernize development workflows.