Since security is the most important issue in the Internet of things (IoT) and blockchain (BC), this article aims to identify, analyze, and organize the literature about security in the IoT and BC context up to August 2020 and proposes an agenda for future research. The 39 related articles have been ranked into three main categories, smart city, data management and information, and architecture and framework. The findings showed that the distinctive technical aspects of BC might impressively find a solution for privacy and security problems encountering the IoT development, supply distributed storage, transparency, trust, and other support for IoT. It is conducted to form a valid, impressive, and secure distributed IoT network and supply a beneficial guarantee for the security of IoT users. Since the devices of IoT are simply reachable, a BC‐depended solution can be executed, which may certify the confidentiality and safety of the info preserved in the devices. In addition, BC technology facilitates the secure sharing of IoT datasets and secure IoT systems. However, blockchains require more computational strength and high bandwidth and are not perfectly proper for many resource‐restricted IoT devices.