We quantify Non Fungible Token (NFT) rarity and investigate how it impacts market behaviour by analysing a dataset of 3.7M transactions collected between January 2018 and March 2022, involving 1.3M NFTs distributed across 410 collections. First, we consider the rarity of an NFT based on the set of human-readable attributes it possesses and show that most collections present heterogeneous rarity patterns, with few rare NFTs and a large number of more common ones. Then, we analyse market performance and show that, on average, rarer NFTs: (i) sell for higher prices, (ii) are traded less frequently, (iii) guarantee higher returns on investment (ROIs), and (iv) are less risky, i.e., less prone to yield negative returns. We anticipate that these findings will be of interest to researchers as well as NFT creators, collectors, and traders.