So you want to self-publish books and courses on programming
Recently, John Resig and I independently published our GraphQL book. While many resources detail how to self-publish books and online courses, guidance on the why and whether is scarce. This post shares my experiences, revenue data, and insights from others who've successfully self-published tech content, weighing the pros and cons of this approach.
Financial Returns
Let's address the elephant in the room: profitability. Initially, I pitched my book to traditional publishers. However, John and I ultimately chose self-publishing. His prior experience with two successful JavaScript books and a blog post critiquing traditional publishing for programming books influenced this decision. His post highlighted:
- Low sales for programming books: Most rarely exceed 4,000 copies.
- Modest earnings: He earned $7,500 from his first 4,000 copies, with a 10% royalty on print and 20% on digital sales.
Randall Kanna's perspective on traditional publishing revenue is blunt: "Nothing comes from a tech book. Just the credibility." While exceptions exist, they're rare. Martin Kleppmann's highly successful machine learning book (O'Reilly's second best-seller in 2019) generated $478,000 in its first three years (108,000 copies sold, 10% print royalty, 25% digital royalty).
The Pragmatic Bookshelf stands out with its 50% gross profit royalty structure. In their first decade, 42% of their authors earned over $50,000, and 12% exceeded $100,000.
Self-publishing offers significantly higher royalty rates:
- Amazon: 70% (e-books); 60% minus printing costs (print books)
- Leanpub: 80%
- Gumroad: 96.5% ($10 monthly membership fee)
- Personal Website: 97%
This potential for higher earnings is evident in successful examples. Discover Meteor generated approximately $500,000 (9,000 copies) between 2013 and 2018 (before becoming free). This success stemmed from significant marketing efforts (detailed in their Gumroad case study) and its status as the go-to resource within the Meteor community. Refactoring UI by Adam Wathan and Steve Schoger is another standout, reportedly surpassing $2 million in sales by 2020. Their success is attributed to effective marketing and addressing a widespread need among front-end developers.
Video courses present different avenues:
- Publisher platforms (e.g., O'Reilly)
- YouTube (e.g., Florin Pop's $4,500 first-year ad revenue from 1.6 million views and 74,000 subscribers)
- Video course platforms (e.g., Egghead, Frontend Masters, Pluralsight, LinkedIn Learning, Udemy – Udemy offers a 97% royalty rate on referred customers and 37% on platform-referred customers)
- Individual services (e.g., Wes Bos's WBaaS model)
- Self-hosting (paywalled content on your own site)
Self-published courses also demonstrate substantial earning potential. While Level Up Tutorials, Kent C. Dodds, and Wes Bos don't publicly share revenue figures, their significant reach (Wes Bos, for example, has sold to over 140,000 individuals) suggests considerable income.
However, these are exceptional cases. Most self-published resources generate significantly less. Consider the comparatively lower earnings of other self-published GraphQL books.
The potential for high returns exists, but it's not guaranteed.
Advantages and Disadvantages of Self-Publishing
The pros and cons discussed below apply primarily to books, but are largely relevant to self-published courses as well, given the shared opportunities and challenges.
Book or Course?
Choosing between a book and a course is highly dependent on individual circumstances.
Reasons to Self-Publish:
- Income Generation: Create a passive income stream.
- Positive Impact: High leverage; a single creation benefits many learners.
- Reputation Enhancement: Boosts credibility and career prospects.
- Personal Learning: Deepens understanding of the subject matter.
- Personal Fulfillment: Enjoyment of the creative process.
Factors Influencing the Decision:
- Writing Proficiency: Clear, concise explanation of complex topics is crucial.
- Marketing Commitment: Active promotion is essential.
- Personal Value: Align the effort with personal motivations and goals.
- Opportunity Cost: Consider alternative uses of time and resources.
My experience demonstrates that while writing the book involved an opportunity cost (lower income compared to consulting), it yielded positive impact, increased knowledge, reputational benefits, and personal satisfaction. The positive feedback from readers is incredibly rewarding.
Acknowledgements: Chris Coyier, Geoff Graham, Sacha Greif, Robin Wieruch, Mandi Wise, Sebastian Grebe, Julian Mayorga, and Rachel Lake provided valuable input for this article.
The above is the detailed content of So you want to self-publish books and courses on programming. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

This is the 3rd post in a small series we did on form accessibility. If you missed the second post, check out "Managing User Focus with :focus-visible". In

The CSS box-shadow and outline properties gained theme.json support in WordPress 6.1. Let's look at a few examples of how it works in real themes, and what options we have to apply these styles to WordPress blocks and elements.

This tutorial demonstrates creating professional-looking JavaScript forms using the Smart Forms framework (note: no longer available). While the framework itself is unavailable, the principles and techniques remain relevant for other form builders.

If you’ve recently started working with GraphQL, or reviewed its pros and cons, you’ve no doubt heard things like “GraphQL doesn’t support caching” or

The Svelte transition API provides a way to animate components when they enter or leave the document, including custom Svelte transitions.

This article explores the top PHP form builder scripts available on Envato Market, comparing their features, flexibility, and design. Before diving into specific options, let's understand what a PHP form builder is and why you'd use one. A PHP form

How much time do you spend designing the content presentation for your websites? When you write a new blog post or create a new page, are you thinking about

npm commands run various tasks for you, either as a one-off or a continuously running process for things like starting a server or compiling code.
