This paper presents the motivation, learning experiences, and practical concerns regarding implementing a code-based method to teach blockchain technology to accounting students. With 53 percent of companies reporting blockchain as a critical priority for their organization, accountants' work will be impacted (Deloitte 2019). Yet, most blockchain education for accountants appears to be limited to theoretical exercises removed from the technology itself. This article details how coding exercises can improve students' understanding of blockchain technology. Students in a graduate accounting data analytics class were introduced to blockchain through a series of scaffolded exercises that engaged them in writing blockchain code in R. Results from implementing this module in a medium-sized accounting program showed that using code-based methods to teach blockchain to accountants was feasible and instructive. We provide code examples and Teaching Notes for those who wish to implement a similar curriculum.