Scaling video delivery in Mendix applications requires thinking beyond the platform’s capabilities. Mendix developers face a significant challenge when implementing video functionality in their applications: the platform’s native approach to video handling simply wasn’t designed for efficient delivery at scale. When your Mendix application serves video content directly, each file must be loaded entirely into memory before delivery to the client. This creates a technical bottleneck that can severely impact application performance, increase costs, and degrade the user experience, especially as video sizes grow or user traffic increases. This is where AWS services can provide a solution, by integrating Amazon S3 for scalable storage and CloudFront for content delivery, a tried and tested pattern that eliminates the memory burden on the server, scales any amount of video content, and maintains high quality while controlling costs.
In this article, you’ll learn:
- Why Mendix’s native approach to video handling creates performance bottlenecks.
- How combining Amazon S3 and CloudFront creates an alternative video delivery solution.
- The benefits that this architecture provides for your Mendix applications.
- How to implement this solution, even if you’re new to AWS services.
Whether you’re building a video-rich learning platform or simply need to incorporate video content in your Mendix project, this approach will help you deliver a superior experience while preserving your application’s performance.
The Challenge: Video Content in Mendix Applications
Mendix provides a robust application development platform, but when it comes to video content delivery, organizations often encounter limitations. The default approach in Mendix applications involves the server retrieving video content from its file storage, loading it entirely into memory, and then serving it to clients. This method works adequately for smaller video files and predictable access patterns, but quickly becomes problematic as your application scales.
The Bottleneck
When a user requests a video in a standard Mendix application, the following process occurs:
- The request is sent to the Mendix server.
- The server locates the video file in the file storage (Amazon S3 on the Mendix public cloud).
- The server loads the entire video file into its memory.
- The server streams the video data to the client’s browser.

This approach can create several issues:
- Memory consumption: Video files can be substantial in size. Loading these files into memory consumes server resources, potentially affecting the performance of other application functions.
- Concurrent access challenges: When multiple users access videos, memory usage multiplies rapidly, potentially leading to out-of-memory errors or degraded application performance.
- Inefficient resource utilization: The Mendix server handles both application logic and video delivery, two functions with vastly different resource requirements and optimization needs.
Common Workarounds and Their Limitations
Organizations often attempt to address these challenges through various workarounds, each with significant drawbacks:
Increasing Mendix Application Resources | Using External Video Links |
1. Creates cost-inefficiencies: File storage needs can grow disproportionately to application logic needs, leading to paying for unused computational resources. | 1. Introduces privacy concerns: Not all video content is appropriate for public platforms. |
2. Doesn’t address root causes: Even with more resources, the fundamental inefficiency of loading entire video files into memory remains. | 2. Creates dependency on third parties: Your application now relies on external services that may change their terms, interface, or availability. |
3. Limits elasticity: Resource scaling is often done in large increments, making it difficult to respond precisely to varying demands. | 3. Limits customization: You have less control over the video player experience and features. |
Why AWS for Your Mendix Video Content?
Mendix and AWS maintain a strategic alliance that extends to cloud deployments and deep application integration. Mendix’s AWS connectors—particularly the Amazon S3 connector—enable seamless uploading from your Mendix application to S3 storage. This content can then be consumed through a CloudFront distribution using the S3 bucket as its origin, creating an efficient solution that remains integrated with your Mendix application.
Before diving deeper, let’s clarify the AWS services at the core of this solution. Amazon S3 (Simple Storage Service) is a highly scalable object storage service designed to store and retrieve any amount of data from anywhere. In our solution, S3 serves as the secure, durable repository for all your video files. The Mendix public cloud uses Amazon S3 as its file storage under the hood. Furthermore, Amazon CloudFront is a content delivery network (CDN) that securely delivers data, videos, applications, and APIs to customers globally with low latency and high transfer speeds. CloudFront distributes your video content from locations closest to your users, reducing buffering and improving playback quality. Together, these services handle the storage and delivery of your video content, allowing your Mendix application to focus on its core business logic.
Technical Compatibility and Performance Advantages
The AWS approach offers several technical benefits for Mendix applications:
- Separation of concerns: By offloading video storage and delivery to specialized AWS services, your Mendix application can focus on its core business logic rather than resource-intensive content delivery.
- Caching intelligence: CloudFront’s sophisticated caching mechanisms are specifically designed for media delivery, placing content closer to users and reducing load times.
- Format conversion: AWS services can handle video transcoding needs, ensuring optimal formats for different devices without burdening your Mendix application.
Cost Efficiency Through Elastic Scaling
The storage-delivery pattern provides significant cost advantages. First of all, storage and delivery costs are scaled precisely with actual usage, eliminating the need to provision for peak scenarios. This means you only pay for what you use. Additionally, CloudFront includes generous data transfer allowances in its free tier, making it cost-effective even for smaller applications. And finally, you only pay premium rates for traffic in regions where your application has users, rather than global flat rates. This approach typically results in lower infrastructure costs compared to scaling Mendix resources to handle the same video workload, particularly for applications with seasonal or unpredictable traffic patterns.
Solution Architecture
Figure 1 shows the process for video delivery in Mendix applications with its known drawbacks; the diagram depicts the following steps:
- The process begins when a client requests video content from the Mendix application.
- Upon receiving this request, the Mendix server’s runtime component needs to locate the requested video file in the application’s file storage.
- This is where the bottleneck occurs, where the entire video file must be loaded into the server’s memory before it can be delivered to the client.
- Finally, the server streams the video content to the client, consuming additional resources throughout the entire playback duration.
This diagram explains why video delivery becomes problematic as either file sizes or user numbers increase. Each video request consumes memory proportional to the video file size, and these resources remain tied up until the streaming is complete. With multiple concurrent users or larger video files, this approach quickly becomes resource-intensive, potentially impacting overall application performance. The diagram clearly shows why an alternative approach is needed for applications where video is an important component – the memory-intensive nature of Mendix’s native video handling creates a technical limitation that the AWS solution addresses.

Figure 2 shows a decoupled approach for video delivery in Mendix applications, the diagram depicts the following steps:
- This step takes place during development time, where you get the CloudFront Distribution location of the content you wish to distribute in your Mendix application.
- Using the location, you configure a video player widget with the location of the content you wish to deliver.
- When an application user wants to view a video, the client directly requests the video content from the CloudFront distribution, bypassing the Mendix server for the content delivery.
- CloudFront receives this request and locates the video in the S3 bucket if it’s not already cached.
- A key advantage occurs here, where CloudFront caches the video content at edge locations, enabling faster delivery for subsequent requests.
- Finally, the video content streams directly from CloudFront to the client, with no Mendix server resources being consumed during playback.
This pattern demonstrates several critical improvements, namely the Mendix server never loads video files into memory, video delivery scales independently from your application, and server resources remain available for core application functions. The diagram shows how we’ve transformed video delivery from a server-intensive process to a scalable one, keeping your Mendix application lightweight and responsive.

Implementation Guide
While understanding the architectural benefits is important, implementing this solution in your own Mendix application makes it tangible. To make this process as straightforward as possible, we’ve created a GitHub repository with detailed implementation instructions.
GitHub Repository Resources
We’ve published an implementation guide on GitHub that provides everything you need to get started. The repository includes a sample video for testing and detailed documentation. Depending on your preference and familiarity with AWS, you can choose between two implementation approaches:
Quick Start with a CloudFormation Template (15 minutes)
For developers looking to get up and running quickly, we provide a CloudFormation template that automates most of the setup process. This approach minimizes configuration and gets your video delivery solution working in just a few minutes.
- Deploy the provided CloudFormation template to your AWS account
- Upload the sample video (or your own content) to the created S3 bucket
- Use the CloudFront distribution endpoint in your Mendix application
Step-by-Step Console Instructions Template (30 minutes)
If you prefer to understand each component of the solution or need to customize specific settings, the repository also includes detailed step-by-step instructions. This approach takes about twice as long as the quick start, but it will surely get you there.
- Creating and configuring your S3 bucket.
- Setting up your CloudFront distribution.
Securing Your Video Content with CloudFront
While providing efficient video delivery is crucial, securing your content from unauthorized access is equally important. Amazon CloudFront offers a versatile set of security features that allow you to control who can see content. While providing efficient video delivery is crucial, securing your content from unauthorized access is equally important.
- Signed URLs: Generate time-limited URLs that provide temporary access to specific video content.
- Signed cookies: Similar to signed URLs, the difference being that it allows access to a subset of files instead of a single file.
- Geo-restriction: Restrict access to your content based on the users’ geographic location.
- HTTPS support: Encrypt data in transit between CloudFront and the app’s users.
These features can be valuable for applications that require content protection, such as video content for premium users of your application, sensitive content in your application for internal purposes, and video courses on an educational platform. For detailed implementation instructions on securing your CloudFront distribution, refer to the AWS CloudFront Developer Guide.
Conclusion
Integrating Amazon S3 and CloudFront with your Mendix application provides a solution to limitations of Mendix’s native video handling capabilities. This approach transforms video delivery from a potential performance bottleneck into a scalable, cost-effective service that enhances your application.
By implementing this architecture, your users will experience benefits:
- Improved application performance: Your Mendix server resources remain dedicated to core application logic, resulting in more responsive user experiences.
- Enhanced video delivery: Faster load times, smoother playback, and quality video content.
- Cost optimization: Resources scale precisely with usage, eliminating the need to overprovision Mendix resources for video handling.
For Mendix developers building content-rich applications, leveraging AWS services like S3 and CloudFront isn’t just a technical optimization—it’s a strategic decision that aligns your application architecture with modern best practices for content delivery.

About the Author
Trong Tran is a technical wizard, a Master of Mendix and an Artisan of Artificial Intelligence.
He is an expert in both technologies, which he could combine perfectly in his previous role as technical consultant and AWS (Generative) AI lead at Mendix itself, and now at The Orange Force as well. If you have any questions regarding AI, Trong is your man! He helped extend the Mendix platform with Smart AWS services, ready-to-use connectors, and AI services.