@AdityaPunjani
Offline-First Progressive
Web Apps
Mobile is key focus area.
• No. of new internet users in India in the last year
alone was one third of United States population.
• 34.8% Internet Penetration.
• 81% of First Time Internet Users are only on
Mobile.
• India to become 2nd largest smart phone market
by 2017.
Source : Mary Meeker’s 2016 Internet Trends Report & Morgan Stanley Report
Offline-First Progressive Web Apps
• Poor User Experience.
• Low Performance.
• Lack of Engagement tools.
Why we shut down our mobile website?
Mobile Web
No storage
requirements
Instant Loading
(No Install Friction) Always up-to-date
Challenges
With Mobile
• Low-end Device Profiles
• Slow Internet Speeds
• Flaky Network connectivity
• Browser Navigation Failures
• Network Congestion
• Low Signal
• Battery Saver Mode
• Thermal CPU Throttling
• Limited Carrier Capacity
• Server Outage
• ISP failure
Unpredictable Conditions
Learnings from Native App.
Architecture
Goals
• App Like Experience
• Build for Offline.
• Optimize for repeat visits
JavaScript (React.js) SPA
+
App Shells
App Shells
Route Defined Route To Render Shell
/:slug/p/:itemid → /slug/p/itemId → Product
/(.*)/pr → /splat/pr → Browse
/search → /search → Search
/accounts/(.*) → /accounts/splat → Accounts
Routes → HTMLApp Shells
• Build Time heavy lifting.
• Lightning fast Response
times.
• Long-term cache.
• Reused across URLs.
• Perceived Performance.
• Fast and smooth
Navigations.
• Rich Interactivity.
• App Like polished
experience.
Single Page App App Shells
Service Worker
• Highly Programmable Low level primitive.
• Progressive Network Proxy in browser.
• Sophisticated Caching policies.
• Lives beyond the Browser Scope.
App Shells - Fastest Strategy
Offline Mode
Strategy
SW-Toolbox
Offline-First Progressive Web Apps
Single Page App - Drawbacks
• JS bundle is huge.
• CSS bundle is huge.
• Bad first load Performance.  
Multiple SPAs Architecture
Each SPA : JS Bundle + CSS Bundle + HTML Shells
Benefits of Multiple SPAs
• Smaller JS Bundles.
• Smaller CSS Bundles.
• Decoupled Deployments.
• Navigations between SPAs allow SW
update, Cache clean up, Heap Memory
Clearing.
Offline-First Progressive Web Apps
Offline-First Progressive Web Apps
Home Screen users
covert 70% more.
3x more Home Screen
additions.
40% more repeat visits.
Biz Requirements
• Cross browser support
• SEO 
Phase II
SEO with App Shells
• Build a cross browser app.
• Web Crawlers do execute JS.
• Keep JS size small.
• Embed SEO critical content in the
App Shells.
• Test using Webmaster tools.
Cross Browser
• Build for the Lowest common Browser engine.
• Optimize for Most common Browser.
• Polyfill / Feature detect every API.
• Tone down Interactions / Animations for older browsers.
• SW as a Progressive Network Proxy.
• PostCSS - Autoprefix and polyfills CSS.
• Conditionally serve JS Polyfills.
PROGRESSIVE
WEB APP
Performance
Phase III • JS Bundle Size growing with
new features.
• Bounce Rate increasing.
Offline-First Progressive Web Apps
Route Based Chunking
(Code - Splitting)
Offline-First Progressive Web Apps
Offline-First Progressive Web Apps
Offline-First Progressive Web Apps
Route Based Chunking
• Prioritized JS Downloads.
• Execute only critical JS.
• Cache-Invalidate only the changed JS bundle.
SPA
App Shells
Route Chunks
0s 2s 4s 6s 8s
First Content Paint First Meaningful Paint
Performance
Offline-First Progressive Web Apps
Requirements
• Extreme Scalability
• Reduce # of network requests
• Fully fault tolerant Web App.
BBD
Offline - First
• Network Resilience: Offline is not an
exception but the norm.
• Serving Strategy: Serve all requests from the
cache (offline) before going to the network.
PRE-BBD Architecture
API Requests
Offline-First
API Requests
Offline-First Architecture
Repeat Visit
SPA
App Shells
Route Chunks
Offline-First
0s 2s 4s 6s 8s
First Paint Meaningful Paint
Performance
“There are only two hard things in Computer
Science: cache invalidation and naming
things.” -- Phil Karlton.
Cache Invalidation
• MaxAgeSeconds based TTL.
• Cache Versions
• Kill Switch
Kill Switch
• Global Cache Version
• No-Cache, max-age=0 HTTP headers on SW.js
• SW self.skipWaiting()
• SW self.clients.claim()
Emergency - Refresh
Offline-First
Network Resilience Reliable Performance Robust Application
Reduced Bounce Rate.
2x BAU Conversion during BBD.
Zero User Perceived Downtime.
Offline-First Progressive Web Apps
Thank You!
@AdityaPunjani

More Related Content

PDF
Progressive Web Apps / GDG DevFest - Season 2016
PDF
Progressive web apps with Angular 2
PDF
Introduction to Progressive Web Apps, Google Developer Summit, Seoul - South ...
PPTX
Progressive Web Apps
PPTX
Pwa demystified
PDF
Progressive Web Applications
PDF
Getting Started with Progressive Web Apps
PDF
Building a Progressive Web App
Progressive Web Apps / GDG DevFest - Season 2016
Progressive web apps with Angular 2
Introduction to Progressive Web Apps, Google Developer Summit, Seoul - South ...
Progressive Web Apps
Pwa demystified
Progressive Web Applications
Getting Started with Progressive Web Apps
Building a Progressive Web App

What's hot (20)

PDF
Progressive Web Apps
PPTX
Pwa.pptx
PDF
Guidance on how to develop a progressive web app using react native!
PPTX
Progressive Web App
PDF
Progressive Web Apps 1. keynote
PPTX
Introduction to Progressive Web App
PDF
From AMP to PWA
PPTX
Progressive web apps
PDF
Building Progressive Web Apps (Kyle Buchanan)
PDF
Building for Your Next Billion - Google I/O 2017
PDF
Introduction to Progressive web app (PWA)
PPTX
Progressive Web App
PDF
Progressive web apps
PDF
The web - What it has, what it lacks and where it must go - keynote at Riga D...
PDF
Progressive Web Apps are here!
PDF
Progressive Web Apps For Startups
PPTX
Progressive web app
PPTX
Progressive Web-App (PWA)
PDF
Next Generation Mobile Web - PWA (Progressive Web App)
PDF
Progressive Web Apps and the Windows Ecosystem [Build 2017]
Progressive Web Apps
Pwa.pptx
Guidance on how to develop a progressive web app using react native!
Progressive Web App
Progressive Web Apps 1. keynote
Introduction to Progressive Web App
From AMP to PWA
Progressive web apps
Building Progressive Web Apps (Kyle Buchanan)
Building for Your Next Billion - Google I/O 2017
Introduction to Progressive web app (PWA)
Progressive Web App
Progressive web apps
The web - What it has, what it lacks and where it must go - keynote at Riga D...
Progressive Web Apps are here!
Progressive Web Apps For Startups
Progressive web app
Progressive Web-App (PWA)
Next Generation Mobile Web - PWA (Progressive Web App)
Progressive Web Apps and the Windows Ecosystem [Build 2017]
Ad

Viewers also liked (14)

ODP
Offline First Applications
PDF
Hitting the couch madrid js
PDF
Chris Wilson: Progressive Web Apps
PDF
Progressive web apps
PDF
Progressive web apps - prepare your web for 2017 (Devfest Ukraine 2016)
PDF
Turku <3 Frontend - Progressive Web Apps, Web and Apps
PDF
Progressive Web Apps - Porque nativo no es significa mejor
DOCX
Estudio jurídico doctrinario pension alimenticia
PPTX
Progressive web apps
PDF
Introducción a las Progressive web apps
PDF
Progressive web apps
PDF
Progressive Web Apps
PPTX
Why Progressive Web App is what you need for your Business
PDF
The Progressive Web and its New Challenges - Confoo Montréal 2017
Offline First Applications
Hitting the couch madrid js
Chris Wilson: Progressive Web Apps
Progressive web apps
Progressive web apps - prepare your web for 2017 (Devfest Ukraine 2016)
Turku <3 Frontend - Progressive Web Apps, Web and Apps
Progressive Web Apps - Porque nativo no es significa mejor
Estudio jurídico doctrinario pension alimenticia
Progressive web apps
Introducción a las Progressive web apps
Progressive web apps
Progressive Web Apps
Why Progressive Web App is what you need for your Business
The Progressive Web and its New Challenges - Confoo Montréal 2017
Ad

Similar to Offline-First Progressive Web Apps (20)

PDF
[TTT Meetup] Enhance mobile app testing with performance-centric strategies (...
PPTX
Benefits of developing single page web applications using angular js
PPTX
Progressive Web Apps
PPTX
SenchaCon 2016: Using Ext JS 6 for Cross-Platform Development on Mobile - And...
PPTX
Decoupled Architecture and WordPress
PPTX
The Art of Mobile Performance (Mobiconf 2015)
PDF
introduction to web engineering.pdf
PPTX
Offline web app - Let's kill the downasaur
PPTX
introduction to web engineering.pptx
PPT
Basic fundamentals of web application development
PDF
5 Steps To Deliver The Fastest Mobile Shopping Experience This Holiday Season
PPTX
Oscon2014 Netflix API - Top 10 Lessons Learned
PDF
A year with progressive web apps! #webinale
PDF
Modern Web Applications
PDF
Finding the sweet spot - blending the best of native and web
PDF
How to be Successful with Responsive Sites (Koombea & NGINX) - English
PPTX
A Day Building Fast, Responsive, Extensible Single Page Applications
PDF
Improve App Performance: Key Tips Explained
PDF
Mobile Performance Testing
PDF
Performance testing of mobile apps
[TTT Meetup] Enhance mobile app testing with performance-centric strategies (...
Benefits of developing single page web applications using angular js
Progressive Web Apps
SenchaCon 2016: Using Ext JS 6 for Cross-Platform Development on Mobile - And...
Decoupled Architecture and WordPress
The Art of Mobile Performance (Mobiconf 2015)
introduction to web engineering.pdf
Offline web app - Let's kill the downasaur
introduction to web engineering.pptx
Basic fundamentals of web application development
5 Steps To Deliver The Fastest Mobile Shopping Experience This Holiday Season
Oscon2014 Netflix API - Top 10 Lessons Learned
A year with progressive web apps! #webinale
Modern Web Applications
Finding the sweet spot - blending the best of native and web
How to be Successful with Responsive Sites (Koombea & NGINX) - English
A Day Building Fast, Responsive, Extensible Single Page Applications
Improve App Performance: Key Tips Explained
Mobile Performance Testing
Performance testing of mobile apps

Recently uploaded (20)

PPTX
AI IN MARKETING- PRESENTED BY ANWAR KABIR 1st June 2025.pptx
PDF
Consumable AI The What, Why & How for Small Teams.pdf
PDF
STKI Israel Market Study 2025 version august
PDF
Convolutional neural network based encoder-decoder for efficient real-time ob...
PDF
Flame analysis and combustion estimation using large language and vision assi...
PPTX
MicrosoftCybserSecurityReferenceArchitecture-April-2025.pptx
PPTX
Module 1 Introduction to Web Programming .pptx
PDF
sbt 2.0: go big (Scala Days 2025 edition)
PPTX
Microsoft Excel 365/2024 Beginner's training
PDF
The influence of sentiment analysis in enhancing early warning system model f...
PDF
Taming the Chaos: How to Turn Unstructured Data into Decisions
PPTX
Training Program for knowledge in solar cell and solar industry
PPTX
Custom Battery Pack Design Considerations for Performance and Safety
PDF
sustainability-14-14877-v2.pddhzftheheeeee
PPTX
Internet of Everything -Basic concepts details
PDF
Five Habits of High-Impact Board Members
PDF
OpenACC and Open Hackathons Monthly Highlights July 2025
PDF
How IoT Sensor Integration in 2025 is Transforming Industries Worldwide
PDF
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
PPTX
TEXTILE technology diploma scope and career opportunities
AI IN MARKETING- PRESENTED BY ANWAR KABIR 1st June 2025.pptx
Consumable AI The What, Why & How for Small Teams.pdf
STKI Israel Market Study 2025 version august
Convolutional neural network based encoder-decoder for efficient real-time ob...
Flame analysis and combustion estimation using large language and vision assi...
MicrosoftCybserSecurityReferenceArchitecture-April-2025.pptx
Module 1 Introduction to Web Programming .pptx
sbt 2.0: go big (Scala Days 2025 edition)
Microsoft Excel 365/2024 Beginner's training
The influence of sentiment analysis in enhancing early warning system model f...
Taming the Chaos: How to Turn Unstructured Data into Decisions
Training Program for knowledge in solar cell and solar industry
Custom Battery Pack Design Considerations for Performance and Safety
sustainability-14-14877-v2.pddhzftheheeeee
Internet of Everything -Basic concepts details
Five Habits of High-Impact Board Members
OpenACC and Open Hackathons Monthly Highlights July 2025
How IoT Sensor Integration in 2025 is Transforming Industries Worldwide
“A New Era of 3D Sensing: Transforming Industries and Creating Opportunities,...
TEXTILE technology diploma scope and career opportunities

Offline-First Progressive Web Apps