Important: Chrome will be removing support for Chrome Apps on all platforms. Chrome browser and the Chrome Web Store will continue to support extensions. Read the announcement and learn more about migrating your app.
Transitioning from Chrome Apps
To transition away from a Chrome packaged or hosted app, the following options are available.
Chrome packaged apps
Recommended migration options for packaged apps are listed in order from simplest to most complicated.
Build a Progressive Web App
Building a Progressive Web
App (PWA) is the ideal way to reach users across all operating systems.
As part of our Web
Capabilities (codename: Fugu)
efforts, we are investigating ways to improve the migration path to the web for
developers that depend on exclusive Chrome App APIs—in particular the Sockets,
HID, File System, and Serial APIs. If there are web platform features you need
that are only available in select
browsers, you can use feature detection to gracefully degrade or include
explanatory text when your app is run in a browser that doesn't support a
particular API. If there are gaps in the web platform for your application,
please let
us know.
PWAs are installable on both desktop and mobile platforms. Users who choose to install your PWA can launch it via icons and shortcuts, similar to the way that Chrome Apps can be installed today.
Build an extension-enhanced web page
If there is a capability that your Chrome App has that the regular web platform can't provide, it might be available as an extension API. In this case, you use a progressive web app together with an externally connectable extension your web app can send messages to. Building a web app is typically preferable to this, because this approach forces users to install an extension that is only useful on your site and can cause increased friction.
As Chrome extensions can't be run on other browsers, you should detect when required functionality isn't available and provide explanatory text for users on these other browsers.
Build an extension
Depending on the user experience you want to provide, it might make sense to convert your entire app into an extension. For example you could provide a browser action button which shows a small popup window for your user interface, or navigates to a page your extension provides. For some apps, this might be a good enough user experience to be a viable solution.
Note there are significant costs to this approach. While some browsers support the same extensions API as Chrome, this support is not universal. This can significant friction for your users who would prefer a cross-browser alternative.
Build for Chrome OS via Android
If you are an Android developer interested in building for Chrome OS, you can optimize your Android application for a better experience.
Chrome App API/Capability migration recommendations (current as of Nov. 2019):
FAQs
Q: What if the Chrome App migration recommendations do not meet my use case requirements?
We'd like your feedback! Please fill out this form with as much detail as possible.
Q: My Chrome App has many users. What's the best way to migrate them to my new web app and deprecate my Chrome App?
You will still be able to publish updates to your Chrome App until the
runtime is removed. We recommend updating your app to include a message
indicating that your app has been discontinued, and that users should visit your
website going forward (see example below). You can also include an "uninstall"
button that calls the
uninstallSelf()
method.
Starting with Chrome 75,
the
installReplacementWebApp()
method can be used inside of a Chrome App, in response to a button click or
other user gesture, to automatically trigger the installation flow for your
replacement PWA.
Q: I want to continue to have a UI affordance that enables users to launch my app from the taskbar/dock/homescreen. What should I do?
Progressive Web Apps are installable on both desktop and mobile platforms. Users who choose to install your PWA can launch it via icons and shortcuts, similar to the way that Chrome Apps can be installed today.
Q: I want my app to run in its own window, not in a tab. Is this something I can do with a web app?
You can provide metadata in your Progressive Web App's manifest file indicating that, when launched after installation, it will open in its own window.
Q: My app supports keyboard shortcuts. Can the web support this also?
Web apps can support keyboard shortcuts by listening to the various key events (e.g. keydown), but the shortcuts you can support are limited. For example, you cannot intercept Ctrl+N, Ctrl+T etc. as these are used by the browser. Or, these might be shortcuts that are handled by the operating system (e.g. Alt+Tab on Windows).
When your web app is used in fullscreen mode, you are able to intercept these system shortcuts.
The Extension Commands API supports richer keyboard shortcuts which operate across the entire browser, which may enable new capabilities if transitioning to an extension is possible.
Q: My app needs to run when the user is offline. Can I do that with a web app?
Yes, you can use service workers to make your site run offline. The Workbox project can simplify developing a full-featured caching strategy for your service worker.
Q: My app uses the chrome.gcm API to receive push messages from the cloud. Can the open web do that?
Yes, assuming the user has granted permission, the Push API and Notifications API can allow your web app to show your user push notifications.
Q: My app needs to be able to show notifications to the user even when it has no windows open. Can I do that with the open web?
Yes, the Push API and Notifications API can allow your web app to show your user push notifications even when your web app is closed, as long as an instance of the browser is running.
Q: My app uses chrome.bluetooth/chrome.usb to talk to a Bluetooth/USB device. Can this be done on the open web?
Both Web Bluetooth and Web USB are available in certain browsers, and can be used (along with feature detection) in a Progressive Web App.
Q: My app uses the chrome.fileSystem API to read and write user-specified files and / or directories. Can this be done on the open web?
The open web can read single files that the user opens, but cannot retain access to those files, write to those files, or have any access to directories.
There are plans to implement direct filesystem access, and an experimental implementation is available in Chrome, but that functionality has not yet been fully standardized.
Q: My app uses the chrome sockets API to do networking. Can this be done with the open web?
You might be able to do what you need with WebSockets. However, to use this, you will likely need to change the remote end of your connection.
If that isn't possible, we'd like to hear more about your use case—please let us know about what you're trying to accomplish via the Chromium issue tracker.
Q: What resources are available to help with a Progressive Web App migration?
The Chrome team maintains the following sites and tools with information that can help during your migration:
- Web Capabilities overview
- Progressive Web Apps Training
- Workbox, for generating a service worker
If you have a specific question not addressed via those resources,
we recommend asking a question on
Stack
Overflow.
This
template
can be used to create a question tagged with both
google-chrome-app
and
progressive-web-apps
,
to ensure maximum visibility.
Q: I'd like to use a capability not mentioned already that lacks a web alternative. How do I make a feature request?
We'd like to hear more about what you're trying to accomplish— let us know via the Chromium issue tracker.
Chrome hosted apps
FAQs
Q: My hosted app uses the notifications permission. How do I do that on the web?
Yes, assuming the user has granted permission, the Push API and Notifications API can allow your web app to show your user push notifications.
Q: My hosted app uses the unlimitedStorage permission. How do I do that on the web?
The unlimitedStorage permission ensured that data you store was ‘Persistent', which means it can only be cleared manually by the user.
The recommended alternative is to request Persistent Storage permission within your web app.
Q: My hosted app uses the geolocation permission. How do I do that on the web?
The Geolocation API can be used in web apps to locate a user's position.
Q: My hosted app uses the background permission. How do I do that on the web?
To ensure minimal power consumption we have been careful about introducing a generic method for sites to run in the background on user's devices.
Sites that have deployed a service worker can ensure actions taken by the user while offline are synced to the server using the Background Sync API. This API allows sites to run some limited code in the background when the device re-connects to the internet, even if the tab has since been closed. Note that this API doesn't allow for the service worker to be woken up periodically.
A separate feature, Periodic Background Sync, is being implemented as an experimental feature in Chrome. It allows developers to request periodic updates via a special event exposed on the service worker, with controls over the frequency of those updates.
Q: My hosted app uses the clipboardRead and/or clipboardWrite permission. How do I do that on the web?
Web apps can use a standard platform API to copy and paste both text and images programmatically.