Why `any maskable` Alone May Not Be Enough for PWA Icons on Android and iPhone

I once thought that adding `purpose: "any maskable"` to a single Manifest icon was the perfect cross-platform solution. It is a valid declaration, but my real-device tests revealed an i

A 1-minute summary

I once thought that adding purpose: "any maskable" to a single Manifest icon was the perfect cross-platform solution. It is a valid declaration, but my real-device tests revealed an important design problem: the same image does not always look right when cropped by Android and displayed more directly on iPhone. A Manifest icon can declare any, maskable, or both. Using both keywords makes one image available for regular and maskable contexts. That looks elegant. The catch is that eligibility and appearance are different questions. Android launchers may apply a circular or other mask. A maskable icon should keep its important artwork inside the safe area. If a logo reaches the edges, it can be cut off.

Next to readWhat I Learned by Using a Nonexistent URL: iPhone’s Hidden Home Screen Icon Behavior

Contents

I once thought that adding purpose: "any maskable" to a single Manifest icon was the perfect cross-platform solution. It is a valid declaration, but my real-device tests revealed an important design problem: the same image does not always look right when cropped by Android and displayed more directly on iPhone.

Why I initially chose any maskable

A Manifest icon can declare any, maskable, or both. Using both keywords makes one image available for regular and maskable contexts.

JSON
{ "src": "/icon.png", "sizes": "512x512", "purpose": "any maskable" }

That looks elegant. The catch is that eligibility and appearance are different questions.

1P1A-EN

Android needs room for cropping

Android launchers may apply a circular or other mask. A maskable icon should keep its important artwork inside the safe area. If a logo reaches the edges, it can be cut off.

iPhone may benefit from a larger-looking image

On iPhone, an icon designed with generous Android-safe padding may look unexpectedly small. A more tightly framed version can look better in the iOS home screen layout.

My preferred approach: two icon assets

Rather than asking one image to satisfy conflicting visual requirements, I prefer to supply a regular icon and a maskable icon separately:

JSON
{
  "icons": [
    { "src": "/icon-any.png", "sizes": "512x512", "type": "image/png", "purpose": "any" },
    { "src": "/icon-maskable.png", "sizes": "512x512", "type": "image/png", "purpose": "maskable" }
  ]
}

This is not a browser requirement to always use two files. It is a design choice that gives each context a more suitable image.

1P1A_EN

The apple-touch-icon decision

For iOS, the HTML may also include:

HTML
<link rel="apple-touch-icon" href="/icon-any.png">

But be careful with dynamic page-specific icons. If a global apple-touch-icon points to a different image, Safari may choose it instead of the icon intended for the current page.

Conclusion

any maskable is useful, but it is not a universal visual fix. Android's cropping behavior and iOS icon selection are separate concerns. If icon quality matters, test both platforms and consider separate assets for their different needs.

OJappTools-en

What I Learned by Using a Nonexistent URL: iPhone’s Hidden Home Screen Icon Behavior

While testing Add to Home Screen behavior in PWA LAB with a nonexistent URL, I found that iPhone can generate a fallback icon from the site name and theme_color.

Ojach

Hi, I'm a solo web developer based in Japan.I'm the creator of One Page. One App. (1P1A), a page-first approach to Progressive Web Apps. I build WordPress plugins and web tools that make it easy to turn individual web pages into installable home screen apps.Most articles on this site are first written in Japanese and then translated into English. While the English may not always be perfect, every article is based on extensive real-device testing with iPhone, Android, Safari, Chrome, Web App Manifest, Service Workers, and modern PWA architecture.

← Back to articles