I have found that you can also use the less long value retention to your advantage by not buying an Android phone on release day. E.g. Pixels often go for hundreds off after 6 months or so. E.g. here in Western Europe, including VAT: Pixel 9a 549 -> 349, Pixel 10 899 -> 549, Pixel 10 Pro 1099 -> 769. At the same time the iPhone 17 has only gone down about 100 Euro. When getting e.g. a Pixel at the discounted price, the loss is not so much after selling after 1-2 years.
Also, I had a habit of getting a new iPhone every year and the loss of selling second-hand is now much larger than in the early days. I think the demand lessened due to the market largely reaching an equilibrium + there not being a lot of advances in smartphones, so people are staying on their phones longer, so there is less demand for second-hand phones (e.g. my parents were on iPhone 11 until recently, my mom still is).
The typical interested buyers are also more annoying to deal with these days (also probably due to the changing iPhone demographics). So nowadays, if I cannot sell it to family or friends, I'll often just send it to a company like Rebuy.
An iPhone does not necessarily last longer than an (flagship) Android phone these days, including security updates.
For a 127 EUR Samsung A17 up to 6 OS and security updates (6 years) are advertised. For a Google Pixel up to 7 updates. How long is it for Apple?
https://www.sammobile.com/samsung/samsung-galaxy-security-up...
Though for price vs. updates it's hard to beat the Pixel 9a. It's currently often ~349 Euro and gets updates until April 1, 2032.
https://www.macrumors.com/2025/02/21/iphone-16e-geekbench-bi...
It was fine without liquid glass, but I unfortunately missed the downgrade window,