Documentation, including README files, is written to help us understand software. Code reading serves the same purpose. The two naturally complement each other, and reading them together can help us gain a deeper understanding of software. (See also: Reading Documentation to Make Code Reading Easier.)
Even though we know that reading a README is a good idea, how many of us make it a habit? Probably even fewer of us actively read README files specifically to support code reading.
One reason we skip README files is that we don’t know how much time and effort it will take to find useful information in them. We have a vague feeling that we might end up wasting our time. So, I decided to look at README files from several open-source software (OSS) projects to see how long they might take to read.
What Does “X Min Read” Mean? #
You may have seen labels such as “5 min read” or “10 min read” on blogs. They give readers an estimate of how long it will take to read an article.
According to Medium, a blogging platform that uses this format, the estimated reading time for an English article is calculated based on a reading speed of 265 words per minute (WPM) [1].
One thing to keep in mind is that these estimates reflect the average reading speed of native English speakers. Several studies involving non-native English speakers at the undergraduate and graduate levels report average reading speeds of around 120–200 words per minute (Pecorari et al., 2024). You can use these figures as a guide and adjust your reading time estimates based on your own reading speed.
How Long Are README Files in Open-Source Projects? #
I selected a set of OSS projects and examined the lengths of their README files. The table below shows the word count and estimated reading time for each README, using 265 WPM as the average reading speed for native English speakers and 150 WPM as an example reading speed for non-native speakers.
| OSS | Language | Words | Mins (265 WPM) | Mins (150 WPM) |
|---|---|---|---|---|
| Node.js | JavaScript | 2,336 | 8.8 | 15.6 |
| Moment.js | JavaScript | 183 | 0.7 | 1.2 |
| terser | JavaScript | 5,109 | 19.3 | 34.1 |
| express | JavaScript | 602 | 2.3 | 4.0 |
| Puppeteer | TypeScript | 135 | 0.5 | 0.9 |
| Deno | TypeScript | 219 | 0.8 | 1.5 |
| Supabase | TypeScript | 512 | 1.9 | 3.4 |
| PyTorch | Python | 2,135 | 8.1 | 14.2 |
| Numpy | Python | 384 | 1.4 | 2.6 |
| Ruby on Rails | Ruby | 571 | 2.2 | 3.8 |
| Mastodon | Ruby | 472 | 1.8 | 3.1 |
| Phoenix LiveView | Elixir | 917 | 3.5 | 6.1 |
| Apache Log4j 2 | Java | 53 | 0.2 | 0.4 |
| syn | Rust | 1102 | 4.2 | 7.3 |
The first thing that stands out is how much README files vary in length from one project to another. They range from lengthy documents that take even native speakers nearly 20 minutes to read to extremely short ones that seem to offer very little useful information. With such a wide variation, it’s understandable that we might hesitate to rely too much on README files.
Still, most of them take less than five minutes to read for native speakers and less than ten minutes at the estimated speed for non-native speakers. If that’s all it takes, wouldn’t it be worth reading a README to pick up some useful information before diving into the code? Counting words every time would be too much trouble, but if you’ve read the Mastodon README, for example, you can use it as a reference to estimate how long another README might take to read.
The difference between the two estimates highlights how much less of a time commitment reading a README can be for native English speakers. Being able to finish one in about three minutes without having to concentrate too hard is a clear advantage. Still, if we can catch up by spending just five extra minutes, it's well worth the effort. For those of us who aren't native English speakers, this difference shouldn't discourage us from making a habit of reading README files.
Reading a Few README Files in Practice #
From the OSS projects listed above, I chose Supabase and Phoenix LiveView and read their README files. I’d seen both names somewhere before, but I knew very little about either project.
It took me four minutes to read the Supabase README and eight minutes to read the Phoenix LiveView README. What I gained was a basic understanding of each project, along with key terms related to how the software works and its internal structure.
For Supabase, I learned that it’s an alternative to Firebase, built by combining several open-source projects with Postgres at its core. The diagrams and tables showing how these components fit together helped me see the big picture. For Phoenix LiveView, I learned that it’s a web framework written in Elixir and understood its key concept: enabling partial updates to a web page.
In both cases, having this kind of background knowledge before reading the code can help us avoid getting stuck. We tend to overlook such information because it doesn’t provide direct clues or answers. However, avoiding situations where we get stuck while reading code is essential to improving productivity. It’s clearly better to avoid losing half a day trying to figure something out than to save a few minutes upfront.
I also found several README files in this survey that were short but offered a useful collection of links to other documentation. Simply finding out where to look for the information you need, without spending much time, can be valuable in itself.
Final Thoughts #
I examined the length of README files to see how much time we would need to spend reading them to support code reading. Although their lengths vary widely, many of them take no more than 10 minutes to read. Even a quick look to pick up key terms or find out where useful information is located can help us when reading code.
Reading a README first may not naturally come to mind when we need to read code. However, spending just ten minutes on a README can give us background knowledge that helps us avoid getting stuck later. Rather than trying to learn everything from a README, we can use it to build a basic understanding of the software before diving into the code. This can make the whole process of code reading much smoother.