On this page
What this issue is
Universal Links let a normal https link open your iOS app instead of the web page. For that to work, your site serves a JSON file called apple-app-site-association at https://yourdomain.com/.well-known/apple-app-site-association. It lists the app ID and the URL paths the app should handle.
Devices do not usually download this file from your server. Apple fetches it and caches it on its own CDN at app-site-association.cdn-apple.com. The phone asks the CDN. If the CDN still holds an older version of your file, iPhones follow the old rules even though your site now serves the new ones.
Why it costs you leads or sales
When you add a new path, such as a campaign landing page or a checkout link, the old CDN copy does not list it. Visitors who have the app tap your ad or email link and land in a browser instead of the app. They lose their cart context, their login or the offer you promised.
The reverse also happens. If you removed a path, the stale copy may still send people into the app for a page it no longer handles. Either way, the link behaves differently from what you tested on your own site, so the problem is easy to miss.
- Ad or email linkVisitor taps a new campaign URL
- Your AASA fileUpdated with the new path
- Apple CDN copyStill the old version
- App opensDoes not happen, opens browser
- In-app conversionLost
Your live file is correct, but the phone reads Apple's older copy.
How to check if your site has it
Fetch both copies and compare them. They should match, apart from whitespace.
# Your live file
curl -s https://example.com/.well-known/apple-app-site-association
# Apple's CDN copy
curl -s https://app-site-association.cdn-apple.com/a/v1/example.com
# Show response headers of the CDN copy
curl -sI https://app-site-association.cdn-apple.com/a/v1/example.comReplace example.com with your domain. If you use an applinks: entry with a subdomain, check that exact host. Look at the appIDs or appID values and the paths, components or substitutionVariables entries. A missing path or an old app ID means the CDN is behind.
| Result | Meaning | Next step |
|---|---|---|
| CDN copy equals live file | Not a CDN problem | Check the app's Associated Domains and the link paths |
| CDN copy older than live file | Stale CDN cache | Wait for refresh, then retest |
| CDN returns an error or empty body | Apple could not fetch your file | Fix the live file first (APP-009, APP-010) |
| Both copies are old | Your deploy did not publish the change | Redeploy and clear your own cache or CDN |
How to fix it
You cannot force Apple's CDN to refresh. What you control is making sure your own file is correct and stable, so the next Apple fetch picks it up.
Confirm your live file is the one you want
Open the
.well-knownURL in a private window. Check the paths, app ID inTEAMID.bundleidform and valid JSON.Clear your own caches
Purge any CDN, host or plugin cache in front of your site so Apple's crawler does not receive an old copy from you.
Serve the file directly
Return HTTP 200 with
Content-Type: application/json, no redirects and no login. Apple will not follow redirects for this file.Wait for Apple to refresh
Apple controls the cache lifetime and does not publish a guaranteed time. Recheck the CDN URL after several hours, and again the next day.
Reinstall the app to test
On a test iPhone, delete and reinstall the app (or install a fresh build) so iOS fetches the association data again.
Upload the file
Place
apple-app-site-association(no extension) in the.well-knownfolder in your site root via SFTP or your host's file manager.Set the content type
Add a rule in
.htaccessor your server config so the file is served asapplication/json.Purge caches
Clear your caching plugin and any host or Cloudflare cache for the
.well-knownpath.
Know the limit
Shopify does not let you upload files to
/.well-known/on your store domain. Universal Links for the store domain usually need the app or a deep link provider to host the file.If you host the link on another domain
Fix and purge the file on that domain, then compare its CDN copy.
Check hosting support
Webflow hosting does not serve arbitrary files at
/.well-known/. Host the file on a domain or proxy you control and point your link domain there.Purge and compare
After publishing, compare the live and CDN copies.
Serve as JSON without redirects
Use the nginx or Apache snippet below, then deploy and purge your CDN.
Version the file in source control
Keep it in your repository so deploys always publish the current copy.
location = /.well-known/apple-app-site-association {
default_type application/json;
add_header Cache-Control "no-cache";
}Stale CDN copy
- New campaign paths missing from Apple's copy
- Links open in Safari for app users
- Your site shows the right file, so it looks fine
CDN matches live file
- Campaign paths listed in both copies
- Links open the app for installed users
- Comparison shows no difference
How to confirm it's fixed
- The CDN URL returns the same paths and app IDs as your live file
- Your live file returns 200 with a JSON content type and no redirect
- You reinstalled the app on a test iPhone
- A new campaign link, tapped from Notes or Messages, opens the app
- The same link opens the web page for a device without the app
How to prevent it happening again
- Use wildcard path rules so new landing pages are covered without edits
- Compare live and CDN copies after every AASA change
- Allow time for the CDN to refresh before launching a campaign on a new path
- Do not put the file behind redirects, logins or bot challenges
- Keep the file in version control and review changes with the app team
Day 1
You add /offer/* to the live file and publish it.
Day 1
Campaign goes live. Apple's CDN still has the old file.
Day 2
App users land in Safari. Nobody notices because the site file looks right.
Day 3
CDN refreshes and links start opening the app.
How FunnelGuard handles this
FunnelGuard detects this issue today. Its app_site_association check fetches the apple-app-site-association file from your site and compares it with the copy on Apple's CDN. When the two differ, you are alerted so you can see that the CDN is behind before campaign traffic hits the affected paths.
Checks run on a schedule. A failure is re-checked from a second region before one alert goes out by email, Slack, Teams, WhatsApp, webhook or PagerDuty, with a likely cause. The Free plan covers 1 site with daily checks and no card, and paid plans have a 3-day free trial. A free read-only website audit is also available.
Questions people ask
Why is my apple-app-site-association file not updating on Apple's CDN?
Apple fetches and caches your file on its own CDN and does not refresh it on demand. Your edit only appears after Apple's next fetch. Make sure your live file returns 200 with JSON and no redirect, then recheck the CDN URL over the following hours.
How do I check Apple's CDN copy of my AASA file?
Open or curl https://app-site-association.cdn-apple.com/a/v1/yourdomain.com, replacing the domain with yours. Compare the app IDs and paths with the file at /.well-known/apple-app-site-association on your site.
How long does Apple's CDN take to update the AASA file?
Apple does not publish a guaranteed time. In practice you should allow several hours and sometimes longer, so avoid launching campaigns on new paths right after editing the file.
Why do Universal Links still open Safari after I fixed my AASA file?
The phone may be using the old CDN copy, or the app was installed before the update. Check the CDN copy matches, then delete and reinstall the app and tap the link from Notes or Messages, not the Safari address bar.
Can I force Apple to refresh the apple-app-site-association cache?
No. You can only make sure your own file is correct, reachable and not cached by your CDN, then wait for Apple's next fetch. Reinstalling the app on a test device makes iOS request the data again.
Does a redirect on the apple-app-site-association file cause stale data?
A redirect can stop Apple fetching the file at all, so the CDN keeps an older copy or has none. Serve the file directly at the .well-known URL with no redirect or login.
How can I be alerted when the Apple CDN copy differs from my site?
FunnelGuard's app_site_association check compares your site's file with Apple's CDN copy on a schedule and alerts you when they differ.
Related issues
- APP-009apple-app-site-association missing, behind a redirect or a login, or served as an HTML pageFix guide
- APP-010apple-app-site-association malformed, over 128 kb, or app id not in TEAMID.bundle formFix guide
- APP-011Campaign URL not covered by the Universal Links rules (path excluded or missing)Fix guide
- APP-015Deep link's web page answers 404 for people without the appFix guide
- APP-013assetlinks.json missing, redirected, wrong content type or malformedFix guide
- APP-001App Store or Google Play link opens the wrong or an old appFix guide