The Internet of Things (IoT) pictures an entire connected world, where things or devices are proficient to exchange a few measured data words and interrelate with additional things. This turns for a feasible digital demonstration of the existent world. Nonetheless, nearly all IoT things are simple to mistreat or compromise. Moreover, IoT devices are restricted in computation, power, and storage, so they are more vulnerable to bugs and attacks than endpoint devices like smartphones, tablets, and computers. Blockchain has remarkable interest from academics and industry because of its salient features including reduced dependencies on third parties, cryptographic security, immutability, decentralized nature, distributed nature, and anonymity. In the current scenario, blockchain with its features provides an anonymous framework for IoT. This chapter produces comprehensive knowledge of IoTs, Blockchain knowledge, security issues, Blockchain integration with IoT (BIoT), consensus, mining, message validation mechanisms, challenges, a solution, and future directions.