Unity WebGL · Performance Engineering
From 1.2GB to 68MB in One Week
TARC restructured a media-heavy Unity WebGL research experience so it could load reliably in a browser, stream video at runtime, record participant choices, and deploy without a conventional backend.
- Original build
- 1.2GB
- Optimized build
- 68MB
- Build-size reduction
- 94.3%
- Delivery
- 1 week
The Challenge
The experience used branching decisions and dozens of pre-rendered videos to deliver a breast-cancer-awareness research journey. Every video lived inside the Unity project, pushing the WebGL download to 1.2GB.
That payload meant slow starts, higher hosting cost, greater crash risk, and participant drop-off that could undermine the quality of the research data.
The Architectural Change
Instead of treating compression as the whole solution, TARC removed the video library from the Unity build, moved the media to Cloudflare R2, and replaced embedded references with runtime CDN streaming.
The player gained loading indicators, fallback handling, and graceful error states so a delayed or failed clip would not leave participants on a blank screen or break the survey flow.
What Was Delivered
- CDN-hosted runtime video delivery
- Unity loading and failure-safe states
- Google Apps Script survey endpoint
- Structured response logging in Google Sheets
- Browser deployment configuration
- 1.2GB → 68MB production build
The Result
The production build fell by 94.3%, from 1.2GB to 68MB. The experience became practical to load, cheaper to host, safer under poor network conditions, and ready for public research deployment within one week.
This TARC case-study page summarizes the delivery. The detailed technical article was originally published by founder Ali Raza and remains the canonical source.
Read the original technical articleIs Your WebGL Build Too Heavy?
Bring the build, target browsers, hosting setup, and current measurements. TARC can identify what is blocking deployment and prioritize the fixes.