I have to say that after trying both of these phones I picked one that I found to be superior, but the other one had some features that just felt better. I will give both of them a fair review and you will be able to make your decision with the information I provide.
For starters I have to say that the Sony Xperia has a slightly lager display and this is something that is not that important since the difference is quite small, but they both responded to the touch without delay when I used light applications such as what Sapp or FB messenger.
There is a huge gap in quality when it comes to megapixels because the Galaxy Note 4 has 16 megapixels and the Xperia only has only 8, but to be fair and honest, this is barely noticeable and you will only be able to see it when it’s dark, but during the day with enough light they both look basically the same.
The processors and built in storage of each phone are quite good but the Samsung comes with a 32GB built-in storage and the Sony Xperia Z Ultra has 16GB. I used both of them to store videos, photos and all kinds of files and they never gave me any problems, but I just felt like overall the Galaxy Note 4 was a bit better for me.
The Xperia Z Ultra is also great though and I would really have a hard time picking one, but if it needs to be done I would say that the Samsung Galaxy note 4 has more power and this makes it the winner on this one.