There is no competition in iOS, Apple dictates the prices. For instance, they can sell a phone that costs 443$ to make for 1250$, while Android phone manufacturers face very strong competition and therefore, have to lower the price down. Getting a much higher profit margin from iPhones lets Apple invest more money into R&D.
There is no strong incentive for Android phone manufacturers to invest a huge amount of money to support older devices. On the other hand, Apple has tons: Apple Pay, App Store (30% cut for all purchases), ads on App Store, iTunes, iCloud, iAds (discontinued for now) and etc. In the Android ecosystem, Google takes all the cake.
Apple can and in fact, makes additional money with contracts. For instance, Google paid 2.9$ billion to Apple to remain the default search engine on iOS devices in 2017. On the other hand, Google requires all Android manufacturers to install Google Chrome and make Google the default engine (otherwise, no Google Play Services / Google Play and etc). On top of that, if a manufacturer ever agrees to this contract, they are forced to make the same choice for all the devices they will ever make. All in or all out. EU recently fined Google 5$ billion because of it, let’s see how it ends. Doesn’t look promising though…
Google also charges for mobile phone certification, I guess it was 25$k per device (couldn’t find the source).
HTC once shared an infographic that shows how time-consuming and long process the update is. While the project Treble reduced the longevity of the process for the phones that are launched with Android 8.0, phone manufacturers still have to make the update. This article shows that after the project Treble Android updates got faster for the main manufacturers, however, it is not enough to expect 3 or even 4 years of updates. Only faster, not longer…
So, considering all this, we all expect that Android phone manufacturers that get very little benefit from selling hardware to keep investing huge amount of money to update the software and make Google rich.
Coming to my opinion, I believe the only way to make long and fast updates possible is by sharing the cake between manufacturers. For instance, letting phone manufacturers use the search engine of their choice, so they can make money out of it. Sharing part of Google Play IAP income with the phone manufacturer from which the purchase was made. Ads within Google Play can remain as it is.
Otherwise, we will end up having only couple Android phone manufacturers that dictate the prices. It is already happening, the company that first started making Android phones declared losses 3 years in a row and looks like this year is their last chance to survive.
P.S: while this post doesn’t cover all the problems related to Android updates, I believe it is enough to picture the problem.