Logo

sr. Larry Ettinng

arrow_back Back to Blog
How to Write Proper Software Documentation

How to Write Proper Software Documentation

Principles, structure, and practical examples for modern software teams


Whenever developers discuss software documentation - at meetups, conferences, or code reviews - the same sentence appears again and again:

“We had to ship fast, and there was no time left for documentation.”

This mindset is understandable, but it is also one of the most expensive habits in software engineering. Documentation is often treated as optional, yet its absence creates long-term friction for teams, customers, and future maintainers.

This article focuses on how to write effective, practical software documentation - not theoretical perfection, but documentation that actually helps people get work done.

Why Software Documentation Is Still Undervalued

Many developers (especially early in their careers) assume that code is self-explanatory. I used to believe this myself. The “documentation” for certain features was:

That approach collapses quickly when:

Documentation is not about writing essays. It is about reducing cognitive load for everyone involved in the product lifecycle.

Documentation as a Developer Skill

Writing documentation is rarely as exciting as building new features. However, over time I learned that communication is a core engineering skill, not a soft add-on.

Good documentation:

The key question is not “Should we document?” but rather:

What is the minimum effective documentation for this audience?

Start With the Reader, Not the System

Every useful documentation effort starts with a clear understanding of its audience.

A typical project includes multiple stakeholder groups:

Each role has different expectations and needs.

Example differences

Trying to serve everyone with one massive document almost always fails.

Three Questions That Shape Good Documentation

Before writing a single line, answer these questions:

  1. Who will read this documentation?
  2. What does the reader need to understand?
  3. What should the reader be able to do afterward?

If you cannot answer these clearly, the documentation will likely miss its purpose.

Focus Beats Volume

From experience:

A focused two-page document that solves one problem is better than a 70-page document that explains everything.

Example

Target audience: Content editors
Goal: Maintain landing page banners

Instead of documenting the entire CMS:

Readability Matters More Than Completeness

Many documentation sets fail not because they lack information - but because readers cannot find it.

A simple but powerful approach was described by Beth Aitman in her talk “Writing Effective Documentation”.

Recommended process:

  1. Write an outline first
  2. Fill it with bullet points
  3. Add details only where needed
  4. Refine structure and headings

More information:
https://bethaitman.com/posts/tld-2019/

Example: Simple Process Documentation

Imagine documenting a deployment script.

Bad example

“Run the deploy command and verify the environment.”

Better example

# Step 1: Install dependencies
npm ci

# Step 2: Build production assets
npm run build:prod

# Step 3: Deploy to staging
./deploy.sh staging

Add context:

Small explanations dramatically improve usability.

Architecture Documentation: Use Proven Templates

For system-level documentation, free-form writing often leads to chaos. This is where structure matters more than prose.

One of the most practical approaches I’ve used is arc42.

Arc42 provides a lightweight but comprehensive structure for architecture documentation.

Typical arc42 sections

Templates are available at:
https://arc42.org/download

You do not need to fill every section. The value lies in shared structure, not in completeness.

Keep Documentation Alive

Outdated documentation is often worse than none at all.

Practical strategies:

If updating documentation feels expensive, the structure is probably too complex.

Characteristics of Good Software Documentation

From long-term experience, effective documentation shares these traits:

Final Thoughts

Software documentation is not about perfection. It is about reducing uncertainty.

Well-written documentation:

If documentation helps someone succeed without asking you for help, it has already paid for itself.

In the end, documentation is not an obligation - it is a force multiplier for good software engineering.

sr. Larry Ettinng

sr. Larry Ettinng

Senior Magento Developer