<p>My new book "<a href="http://www.lulu.com/shop/paul-huang/a-dissection-of-bitcoin/ebook/product-22482928.html" rel="noreferrer">A Dissection of Bitcoin</a>" examines the original Bitcoin source code written by Satoshi.</p>

<p>As for now, it is the first and only book available that helps you read the Bitcoin source code.</p>

CC BY-SA 3.0
2017-10-25T13:42:22.830Z
I've seen the book for sale online but it appears to be only four chapters. (iTunes: "The whole book has 10 chapters. This version you are about to purchase contains the first 4 chapters.") --- Where can I get the full 10-chapter version?
Daniel
CC BY-SA 3.0
2017-10-25T13:49:38.920Z
Never mind, found the full version [here](https://ebook.ubiqlink.com/).
Daniel
CC BY-SA 3.0
2018-04-01T20:33:34.007Z
Can you please release new book version for 2018? I want to buy cause i am working on 2018 but your book is very very very very old.
YumYumYum
CC BY-SA 4.0
2018-08-19T01:21:42.013Z
@paul-huang, can I still purchase the full version?
sinoTrinity
CC BY-SA 3.0
2015-12-13T03:50:21.873Z
2015-12-29T04:21:19.927Z
2015-12-29T04:21:19.927Z
Paul Huang
<p>The Bitcoin codebase is a very large today, with roughly 370,000 lines of code in the 0.17.0 release. </p>

<p>There is a Github project that help developers read open source projects. Check out the entry on Bitcoin:</p>

<p><a href="https://github.com/CodeReaderMe/awesome-code-reading/issues/2" rel="nofollow noreferrer">https://github.com/CodeReaderMe/awesome-code-reading/issues/2</a>. </p>

<p>It contains an overview of the Bitcoin codebase as well as some tips to get you started.</p>

CC BY-SA 4.0
2018-10-23T22:45:26.407Z
2018-10-23T22:45:26.407Z
Lucas Lee
<p>Aside from what @Murch♦ mentioned above (especially the developer reference), a good source for this is the Doxygen documentation. You can generate it locally or it seems to be published here:</p>

<p><a href="https://dev.visucore.com/bitcoin/doxygen/" rel="nofollow" title="Doxygen for Bitcoin">Bitcoin: Developer documentation</a></p>

<p>Unfortunately the documentation itself is pretty sparse, but the things that Doxygen adds (especially call graphs and inheritance graphs) add a lot more than what you would get just by browsing the source in an editor.</p>

CC BY-SA 3.0
2015-05-31T19:28:36.487Z
2015-05-31T19:28:36.487Z
Hut8
<p>You might benefit from understanding key concepts in bitcoin before diving into the core source code. The following link teaches the technical basics of how Bitcoin works by walking you through writing a simple python script to create transactions from scratch:</p>

<p><a href="http://www.righto.com/2014/02/bitcoins-hard-way-using-raw-bitcoin.html" rel="nofollow">http://www.righto.com/2014/02/bitcoins-hard-way-using-raw-bitcoin.html</a></p>

<p>Also on the site are other posts on how Bitcoin mining works and how to write a python script to mine Bitcoins (for science and understanding, PROFITABLE cpu/gpu mining days are long gone)</p>

<p>You might benefit from some fundamentals of what the Bitcoin blockchain actualy is. James D'Angelo is awesome at explaining concepts to everyone including beginners and more advanced users, without being boring or confusing. Watch the following video and check out his channel for more info. 
<a href="https://www.youtube.com/watch?v=gUwXCt1qkBU" rel="nofollow">https://www.youtube.com/watch?v=gUwXCt1qkBU</a></p>

CC BY-SA 3.0
2015-12-13T05:49:20.907Z
2015-12-14T12:59:17.817Z
2015-12-14T12:59:17.817Z
Dean Dunbar
<p><a href="http://chimera.labs.oreilly.com/books/1234000001802/index.html" rel="nofollow"><em>Mastering Bitcoin</em></a> by Andreas Antonopoulos is definitely a good start. It's available for free.</p>

CC BY-SA 3.0
2015-06-28T06:06:08.287Z
Yeah, previous answers already mention it. Also, posting your amazon referral link here doesn't benefit you, as the Stackexchange engine automatically replaces the link with its own referral.
Murch
CC BY-SA 3.0
2015-06-27T22:20:34.967Z
2015-12-13T10:17:20.403Z
2015-12-13T10:17:20.403Z
Gurmlo
<p>I am not aware of an extensively commented version of the Bitcoin sourcecode, but you could check out the <a href="https://bitcoin.org/en/developer-reference#">Bitcoin Developer Reference</a> and you can read online the book <a href="http://chimera.labs.oreilly.com/books/1234000001802/index.html">Mastering Bitcoin</a> by Andreas M. Antonopoulos, which covers Bitcoin's technical aspects extensively. There is also <a href="https://www.youtube.com/watch?v=fOMVZXLjKYo">Princeton's Free Online Bitcoin course</a>, which goes into details on some technical aspects, which might in turn help you understand the sourcecode better.</p>

<p>Besides that, try searching Bitcoin.SE for specific questions, there are a few here that have been asked about already, if you can't find something, feel free to ask a new question here.</p>

CC BY-SA 3.0
2015-05-31T13:25:18.247Z
Thank you. I am reasonably comfortable with the theoretical aspects. I am looking for pure implementation details like critical sections and libraries used and such..
user2277550
CC BY-SA 3.0
2015-05-31T16:34:47.677Z
It is probably the easiest if you then ask specific questions about any sections of the sourcecode you want to understand better. Alternatively, you might want to try asking advice in #bitcoin-dev on freenode, where a lot of Bitcoin contributors hang out regularly.
Murch
CC BY-SA 3.0
2015-05-31T13:23:46.770Z
2015-05-31T13:23:46.770Z
Murch
<p>I am looking to understand the Bitcoin C++ source code on <a href="https://github.com/bitcoin/bitcoin">GitHub</a>. The Python one is simpler, but even that is too complicated for a beginner. Could someone guide me to some good resources on the actual implementation and its details? The actual C++ techniques used seem to be quite complicated.</p>

CC BY-SA 4.0
2019-03-07T19:37:57.647Z
I answered this question [here](https://bitcoin.stackexchange.com/questions/41692/how-to-understand-bitcoin-source-code/85078#85078). Do check. Also, I have written a [blog](https://vishwas.netlify.com/post/bitcoin-stellar-build/) on this topic, might help you.
Vishwas Bhushan
<bitcoin-core-development><open-source>
Where to find help understanding Bitcoin's source code in C++?
user2277550
# Where to find help understanding Bitcoin's source code in C++?

(Asked by: username_0 on 2015-05-31)

I am looking to understand the Bitcoin C++ source code on [GitHub](https://github.com/bitcoin/bitcoin). The Python one is simpler, but even that is too complicated for a beginner. Could someone guide me to some good resources on the actual implementation and its details? The actual C++ techniques used seem to be quite complicated.

**Tags:** bitcoin-core-development, open-source

> **Comments:**
> **username_1**: I answered this question [here](https://bitcoin.stackexchange.com/questions/41692/how-to-understand-bitcoin-source-code/85078#85078). Do check. Also, I have written a [blog](https://username_1.netlify.com/post/bitcoin-stellar-build/) on this topic, might help you.  

---

## 6 answers

### Answer by username_10 on 2015-05-31. Score: 12 | Accepted answer

I am not aware of an extensively commented version of the Bitcoin sourcecode, but you could check out the [Bitcoin Developer Reference](https://bitcoin.org/en/developer-reference#) and you can read online the book [Mastering Bitcoin](http://chimera.labs.oreilly.com/books/1234000001802/index.html) by Andreas M. Antonopoulos, which covers Bitcoin's technical aspects extensively. There is also [Princeton's Free Online Bitcoin course](https://www.youtube.com/watch?v=fOMVZXLjKYo), which goes into details on some technical aspects, which might in turn help you understand the sourcecode better.

Besides that, try searching Bitcoin.SE for specific questions, there are a few here that have been asked about already, if you can't find something, feel free to ask a new question here.

> **Comments:**
> **username_0**: Thank you. I am reasonably comfortable with the theoretical aspects. I am looking for pure implementation details like critical sections and libraries used and such..  
> **username_10**: It is probably the easiest if you then ask specific questions about any sections of the sourcecode you want to understand better. Alternatively, you might want to try asking advice in #bitcoin-dev on freenode, where a lot of Bitcoin contributors hang out regularly.  

---

### Answer by username_2 on 2015-12-13. Score: 8

My new book "[A Dissection of Bitcoin](http://www.lulu.com/shop/username_2/a-dissection-of-bitcoin/ebook/product-22482928.html)" examines the original Bitcoin source code written by Satoshi.

As for now, it is the first and only book available that helps you read the Bitcoin source code.

> **Comments:**
> **username_3**: I've seen the book for sale online but it appears to be only four chapters. (iTunes: "The whole book has 10 chapters. This version you are about to purchase contains the first 4 chapters.") --- Where can I get the full 10-chapter version?  
> **username_3**: Never mind, found the full version [here](https://ebook.ubiqlink.com/).  
> **username_4**: Can you please release new book version for 2018? I want to buy cause i am working on 2018 but your book is very very very very old.  
> **username_5**: @username_2, can I still purchase the full version?  

---

### Answer by username_6 on 2018-10-23. Score: 3

The Bitcoin codebase is a very large today, with roughly 370,000 lines of code in the 0.17.0 release.

There is a Github project that help developers read open source projects. Check out the entry on Bitcoin:

<https://github.com/CodeReaderMe/awesome-code-reading/issues/2>.

It contains an overview of the Bitcoin codebase as well as some tips to get you started.


---

### Answer by username_7 on 2015-05-31. Score: 2

Aside from what @username_10♦ mentioned above (especially the developer reference), a good source for this is the Doxygen documentation. You can generate it locally or it seems to be published here:

[Bitcoin: Developer documentation](https://dev.visucore.com/bitcoin/doxygen/ "Doxygen for Bitcoin")

Unfortunately the documentation itself is pretty sparse, but the things that Doxygen adds (especially call graphs and inheritance graphs) add a lot more than what you would get just by browsing the source in an editor.


---

### Answer by username_8 on 2015-12-13. Score: 1

You might benefit from understanding key concepts in bitcoin before diving into the core source code. The following link teaches the technical basics of how Bitcoin works by walking you through writing a simple python script to create transactions from scratch:

<http://www.righto.com/2014/02/bitcoins-hard-way-using-raw-bitcoin.html>

Also on the site are other posts on how Bitcoin mining works and how to write a python script to mine Bitcoins (for science and understanding, PROFITABLE cpu/gpu mining days are long gone)

You might benefit from some fundamentals of what the Bitcoin blockchain actualy is. James D'Angelo is awesome at explaining concepts to everyone including beginners and more advanced users, without being boring or confusing. Watch the following video and check out his channel for more info.
<https://www.youtube.com/watch?v=gUwXCt1qkBU>


---

### Answer by username_9 on 2015-06-27. Score: -2

[*Mastering Bitcoin*](http://chimera.labs.oreilly.com/books/1234000001802/index.html) by Andreas Antonopoulos is definitely a good start. It's available for free.

> **Comments:**
> **username_10**: Yeah, previous answers already mention it. Also, posting your amazon referral link here doesn't benefit you, as the Stackexchange engine automatically replaces the link with its own referral.  

---

