“Hi Nir,” the email began. “I have been reading your work and find it incredibly interesting.” Naturally, this is the kind of message a blogger loves to receive. However, this email was special for another reason. It was from a prominent New York publishing agent who represents several authors I read and admire. “I don’t know if you’ve already started down this road or whether writing a book interests you, but I’d be delighted to have a conversation with you if you are interested.”

Was she kidding? Heck yeah I was interested!

We scheduled a time to talk. She told me she is fond of my work and thought it could reach a larger audience if it was promoted by a major publisher. That email and the subsequent call would lead to the release of my book, Hooked: How to Build Habit-Forming Productswhich just debuted on the Wall Street Journal bestseller list this week.

I should mention that the focus of my research for the past several years — and the topic of my book — is mind hacking. I study the psychology of how products change human behavior. Given my knowledge of the subject, I’d be foolish not to use what I teach others. Here are three surprising techniques I utilized to write my book and a few tips from some very successful friends; tips that may help you with your work and help you write a book.

Write What You Want to Know

When Daniel Pink began working on his mega-hit book, Drive, he knew relatively little about the subject he was going to write about. What he did know for certain was that his curiosity was not yet satisfied. Pink told me he knew “enough to realize that the science of motivation was utterly interesting but woefully under-covered.” Interestingly, the more Pink learned, the more things fit into place. Today, Pink is an expert in his own right.

Curiosity is author rocket fuel. In my own book, I describe the psychological power ofvariable rewards. Receiving positive reinforcement at variable intervals — that is, not knowing when the good stuff is coming — has been shown to spike dopamine levels in the reward centers of the brain. It is a major reason why all sorts of experiences like video games, slot machines, action movies, and even our cell phones, keep us so engaged. For authors, searching for the answers we seek can be just as engrossing. The unpredictable nature of the hunt for knowledge can provide endless motivation for those able to harness it.

As Pink told me, “The big motivator for good books is the author’s own curiosity. If I’m not curious about a topic, why should I expect any reader to be?” Leveraging the variable reward of pursuing answers to one’s own burning questions is one of the best mind hacks I know.

Get Frequent Feedback

Many would-be authors believe they have to know all the answers before they start writing. Whether it’s a full volume book or a 500 word blog post, people tend to not start until they have all the pieces of the puzzle figured out. Generally, this leads no where. Far too many people who have important things to share never publish because they fail to take the first step.

When New York Times bestselling author Gretchen Rubin began working on her forthcoming book, Better Than Before, she admits that like Pink, she didn’t have all the answers. “If I have what I think is a good idea, I want to get it out into the world,” Rubin told me. “I don’t hold ideas back.” Despite knowing her ideas were only half-baked, Rubin began putting her thoughts and theories out into the world via her blog because, she says, “I learn more about them as I write about them and also because my creativity is more stimulated by throwing ideas out there … Often I will write a post about a new idea to see what responses it evokes.”

In my own book, I detail the psychology behind taking action. Psychologists have known for years that when a behavior is difficult to do, we need more motivation and willpower to do it. For many people, the burden of needing to have all the answers before writing, make the book writing journey too difficult to start. Instead, breaking down the process into small iterative steps can reshape and improve the work. Publishing small posts frequently with the intention of testing new ideas with readers not only provides a constant stream of critical feedback but also supplies a kind of intoxicating encouragement that can push an author forward.

Help Your Readers Invest in Your Work

Like Gretchen, the content of my book started as blog posts. After I had published my thoughts for several years, I began to see common themes emerge. I turned my posts into a series of lectures I later taught at the Stanford Graduate School of Business. As my blog readership grew, I received a few emails asking when I’d write a book. One of those messages came from Ryan Hoover who offered to help arrange my essays into a book format. Ryan’s work also helped identify holes in the text where I needed to do more research and writing.

When I had completed a rough draft, I decided to ask my blog followers for help and did something most authors would think is nuts — I placed the full text of the book online. Certainly, some people may think giving the entire world access to an unpublished book is crazy. However, the response was tremendous and the experience taught me something profound. By letting people make suggestions and improvements, readers were also investing in the book with their time and effort.

Psychologists have studied the powerful influence small investments can have on the way we think and act. Several studies have demonstrated that putting effort into an activity makes us more committed to it. A happy by-product of asking my readers for help editing my book is that I now have a team of advocates ready to tell others about the book they helped create. I also made sure to list the names of everyone who helped in a special contributor section in the book.

When I received my literary agent’s email asking if I was interested in publishing a book, I was ready. I had put the psychological principles featured in my book to good use. By following my own curiosity, getting frequent feedback and asking my readers to invest in the text, I was in a great position to take my book to stores and eventually readers’ hands.

I am extremely grateful for the interest and support of my early readers. Hooked is for you and in many ways by you. Thank you!