On the software side it's kind of hard to say for certain because so much of the software world started in the US before being replicated elsewhere so is it nationalistic preference or just first-mover preference? I'm not sure. But I am pretty sure it's not even close to the same level as in China.
Much of the rest of the world also favors US software from Microsoft and Google.
Apple is just one company. Some American switching from a Mac is just as likely to buy a Microsoft or Dell product, or even a Lenovo, running American software. Or if they switch from an iPhone to a Samsung, Sony, LG, or OnePlus phone, it is likely running American software.
Do we have a nationalistic preference for buying our own products? I think the answer is some of us and sometimes. If it were pervasive or strongly held, companies like Toyota or Honda or Sony would never have made inroads here in the first place. I think on average, when we buy an American product, it’s because we like the American product more on its own merits. That’s why Japanese car companies can so thoroughly dominate the market for sedans while Ford and GM can so thoroughly dominate the market for trucks.
https://www.statista.com/statistics/283334/average-smartphon...
Are you American? I suspect either you're not, or we live in very different parts of the country. I do believe that most Americans would say that they prefer American made over otherwise, but I don't believe more than a small subset actually stick to that when making purchasing decisions unless American made vs Non-American made is the only difference between two choices, which is rare.
Edit: It's late and I'm tired so perhaps I'm missing something, but looking at this [1], I'm not really seeing any data to back up the statement that America "overwhelmingly favour[s] Apple compared to the rest of the world." UK, Canada, Norway, Ireland, Denmark are all at similar levels of iOS adoption compared to the US, and Japan is far higher. At a glance, I'd guess that iOS adoption is pretty correlated with a country's economy. The least popular places for iOS are Argentina, Brazil, Colombia, Egypt, India, Indonesia, Malaysia, Ukraine, South Africa.
Similar story with Xbox vs the far more globally popular PlayStation video game consoles.