Recently, the term “Internet of Things” (IoT) has elicited escalating attention. The flexibility, agility, and ubiquitous accessibility have encouraged the integration between machine learning (ML) with IoT. However, there are many challenges that present the key inhibitors in moving ML to the public solution, such as centralized training, poor training efficiency, and heavy computing capabilities requirements. Therefore, bringing learning intelligence to edge IoT nodes has been spotlighted for some researches. Meanwhile, how to govern the use of learning results efficiently, reliably, scalably, and safely is hampered by the heterogeneity and nonconfidence among IoT nodes. In this article, we propose a blockchain-based collective Q-learning (CQL) approach to address the above issues, where lightweight IoT nodes are used to train parts of learning layers, then employing blockchain to share learning results in a verifiable and permanent manner. We further improve the traditional Proof of Work (PoW). Instead of solving a meaningless puzzle, we regard the learning process in the IoT node as a piece of work. Accordingly, the winner is the IoT node with the minimum reduced percentage of the learning loss function, referred to as the Proof-of-Learning (PoL) consensus protocol. Specifically, in order to show how the CQL approach works, we use it to address a networking integrated cloud-edge-end resource allocation in IoT. The experimental results reveal the superior performance of the proposed scheme.