But a pixel is quite a bit more expensive no? At that point you can consider an iPhone?

If you'd prefer an Iphone if it weren't for price, you should probably have a look at refurbished Iphones.

If you are the kind of person who unlocks the bootloader and installs GrapheneOS, then definitely not.

The Pixel can run Graphene, which means you can permanently take control of the phone and give Google the boot. The iPhone is entirely controlled by Apple, and you are one OTA away from a hostile "upgrade." By default, everything on your phone is sent to Apple for "backup" too.

I got a pixel 10 for 350 a few weeks ago.