No tags :(

Share it

It pains me to see people spending so much money and time on the easiest format for indie publishing: the ebook. Anyone with a little bit of patience and free software can create their own ebooks without learning html or hand crafting them. The tools are out there, you just need to know how to use them.

Most suggestions for ebook create involve going in and manually editing the html files. You can do that if you know how. I don’t find it that hard, but I used to do typesetting and electronic conversion for a living and part of my current job is web design. If you want an alternative or just don’t feel like fussing around in html (and I don’t), then it’s not that hard to fix these problems if you use a combination of Microsoft Word (Or LibreOffice’s word processor or Google Docs) and Calibre.

We’re using Word to style the text in basic ways, then we’re using Calibre to strip out the stuff Microsoft puts in that we don’t want and to create a table of contents. This system will produce not only an HTML table of contents in the body of the book, but it will also create an NCX TOC for the various devices “go to” menus.

The TLDR (too long didn’t read) version of this guide is style everything in normal except for chapter headings. Put them in Heading 1. Save as docx with no spaces in the file name, import to Calibre, set the TOC setting under conversions to H1 so it will automagically make a TOC, then convert. Done.

Also, this guide is for a more or less run of the mill short story, novel or biography or anything that’s a text based book without a large number of pictures or charts or anything like that. That covers most of what we write. Wouldn’t work for this guide though as it has all sorts of graphics.

First go to the Calibre Website and install the program. I’ll explain how it works later. It’s available for Windows and Mac.

Now, we need a proper Word file. This may require some “nuclear method” work to clear out formatting that we don’t want and it will require you to use “styles.” First make an extra copy of your manuscript and put it away somewhere in case we screw it up. Always keep a backup! Then open it up in Word.

At the top of the Word window, you will see a bunch of different icons on “the ribbon.” This guide was created with Word 2007. Word 2010, 2013, or 2016 will be similar. Word 2003, Google Docs, or Libre Office won’t be, but you can probably figure it out. The ability to redefine a style is available in all the programs, it’s just a matter of where things are.


These are styles and they are the key to how you format. The way to get files that are easy to convert between different formats is to do as little “manual” formatting as possible. Styles let you set a whole bundle of formatting and apply it at once. “Normal” is the style we are going to put our text into and “Heading 1” is what we’re going to use for our chapter titles.

Go to the top bar and find the little paragraph symbol icon. If you hover it will say “show/hide.” This will reveal some of the hidden code in a document, most importantly the tabs and end of paragraph marks. It’s also control-* if you like keyboard commands.


We don’t want any tabs. Tabs are evil! The spawn of Satan. Worse than the trad publishing gatekeepers! If you indented your paragraphs with tabs rather than with styles or the ruler, we need to get rid of them. Control-H brings up the search and replace box. Word’s search functions are incredibly powerful and one of the things they can do is search for paragraph returns (^p) and tabs (^t).

So click control-h and in the top “find what” box type ^p^t and in the bottom “replace with” type ^p Click replace all. Your tabs should be gone. (If you never had any, you don’t need to do this.) If you have more than one tab in a row, you may need to run that search and replace more than once.

Now let’s get rid of double paragraph returns. Control H: Top “find what” box ^p^p and bottom “replace with” is ^p. (Don’t worry about the paragraphs being too close together, we will go back and fix that with styles.)

Finally, typeset books, print or ebook, only need one space after a period. Two spaces in the top box and one in the bottom. Again, with all of these searches, repeat them until the program reports it didn’t find any instances of what you’re searching for.

Now we’re going to get rid of any extra formatting. Here’s a trick I learned when I was doing typesetting for a living. In Microsoft Word, the last paragraph return of a document is “special.” (Isn’t everything from Microsoft a little “special?”) If you Select All and format something with a style, you can get very different results than if you select everything except the last paragraph return.

So we want our entire document to be on “normal” style, but instead of selecting all, instead we go to the end and add one extra paragraph return. (Remember when we turned on the show invisible above? This is why.) Then we select everything except that last paragraph return and press the button on the ribbon for “Normal” style. This will set line spacing, indents, and justification to match the “normal” style, but it won’t override italics or bold. It’s not the nuclear option, it’s kind of the tactical nuclear option. (The “nuclear option” is a trick of moving something to a text editor so it strips out all formatting, but that means losing all those italics and putting them back in is a major pain in the posterior. This should do the trick. If it doesn’t, nuke ’em till they glow.)

At this point, you may want to go through the document and make sure it really got everything. Some versions of Word won’t overwrite certain types of formatting. I can’t keep track of which version does what, you really need to look for it, fortunately, it’s usually pretty easy to eyeball.

Now we need to set up normal as we want it to be.

Right click on “normal” button at the top of the ribbon and select “Modify Style.”


Nothing here is really important. Don’t worry about what font you’re using because later in the process we are going to strip out the font so ebook we create will use the default font for the device. At the lower left hand corner is a little button called “format.” This is where the magic happens. While Calibre will strip the font face and size out, most of what’s in this box will survive the conversion to ebook, so it’s where we get to try our best to make it look nice.


There are a number of important things here.

See where it says “special” and I’ve selected “First line” and set it at .25″ That’s setting a small indent at the beginning of each paragraph. I know term papers and manuscript format set this to a half inch, but .5″ is too damned big and it really doesn’t look good on a tablet or ereader.

See where it says “spacing” and “after” and I’ve set 4 points? That’s going to tuck just a little bit of extra space between our paragraphs. Some people don’t think there should be any space, but I set a little bit because I think it makes it easier to read on an eink tablet. But what you want to avoid is a full double space or even a space and a half. That just looks terrible when you translate it to the small screens of a reader.

If you don’t want indents and instead want block paragraphs with a double space between them, you should set this at something like 24. You shouldn’t use double paragraph returns because some e-readers will just ignore two in a row. This particular style of double spaced paragraphs is generally used by non-fiction and you will probably find that some readers, such as myself, will curse your souls to eternal damnation if you use it for fiction.

Now hit a bunch of oks and you should see the changes happen automatically to all your text.

Now we want to right click on the “Heading 1” button. You can set this however you want. Here, size does matter. You probably want your chapter headings to be a little bit bigger than the body text. I’ve also set it so there’s a bunch of space before and after the heading to set off the Chapter title from the text. (Putting space before them is how you get them to appear part way down the page btw–this may not appear when you look at it in Word, but it will translate to the ebook.) I even checked a button to make them all caps. How you want your chapter heads is up to you. I think the default in Word is to put them in light blue, you probably want to change that. I just use simple uncolored ones, but if you do add color here, it won’t be a problem for e-ink (b/w) readers like the basic Kindle or PaperWhite. It’ll just make them black or grey.


Now one more thing. We want our chapters to start on a new page so under the paragraph box, click on “Line and Page Breaks” and put a check next to “Page break before.”


Now click a bunch of OKs. Nothing should happen because we set the entire document to be “normal” and these changes are for “Heading 1.” Now go find your chapter headings and click anywhere on them and then press the “Heading 1” button at the top of the ribbon. It should jump into a larger font, centered (or however you set it up) and put a page break before it. You can also use search and replace to apply a style, but you have to be careful as the word chapter might appear somewhere in the book.

Once we have “normal” applied to the body text and “Heading 1” to our chapter titles, the big work is done in Word. You can do the same thing in LibreOffice or Google Docs. I’ve tested it, and maybe someday I’ll do another version with those graphics, but not today. You should be able to figure it out.

You can and should also go and fix any other formatting like centering ***’s if you use them for scene breaks or removing the indent in the first paragraph got a chapter or scene. I actually create styles for these as well.

Here’s a tip. Scenes are separated either with a centered *** or a non-indented paragraph with a double space between it and the previous paragraph. In either case, some epub programs and readers won’t like it if you use a double paragraph returns. If you don’t want to create styles, you can instead, click on the little arrow at the lower right of the paragraph button on the ribbon and set some extra space before and after them. It’s the same dialog box as when we set up our indents for the normal heading.


If your book contains any pictures in the text you want to keep them as simple as possible. Type an extra return to get a blank line and then go to “insert picture.” Do not fiddle with any of the other picture settings with borders or anything else.

Now you’re going to need some “alternative text” that will display on any device that doesn’t show pictures. If you don’t have this alternative text, it will fail epubcheck and you will get rejected from some stores. To do this right click on the picture. You’re looking for “alt text.” In Word 2010 it’s under “format picture” and in Word 2007 it’s under “size.” By default this will be the filename of the picture, but epubcheck doesn’t seem to like that so change it to anything. Really, anything. Nobody’s ever going to see it, but epub check will bounce you without it.

A note about pictures. Ebook readers don’t recognize transparency, so if you have something like a little graphic you put between scenes or at the beginning of chapters, it will have a white background. If someone on a tablet version of a reader reverses the screen so it’s white text on a black background, the graphics will appear in white boxes. You can’t do anything about this and I would encourage you to not worry about it. The same thing will happen to all those fancy trade published books too.

Now we need to save our document. Prior versions of this guide suggested filtered HTML, but right now the best format to convert from is “docx” the Word file format used since Word 2007. Also, and this is very important, pick a single word name for your save. Ie, save as “book.docx” not “the full title.docx” The reason for this is that when we convert to epub, some versions of Calibre will use the name of the original file for some internal stuff and if it has spaces, it will fail epub validation.

Now run the Calibre program. The first thing that confuses people about Calibre is that everyone recommends it to convert files, but it doesn’t seem to have options to do that. Calibre’s real purpose is as a library manager, conversions are secondary. So first we need to add a book to our library.

Click on the red “add books” button, then navigate to the docx file you just saved and add it to calibre.


You’ll see your book appear. Sort of. The title will be the title of the file and the author name will be blank.


Highlight your title and click on the blue “edit metadata” button.


The edit metadata screen will appear.


This is where we fix our title, author name, and add other “metadata. See how I fill it out? You also add your cover here. Click on browse and find your cover and it will import it. You must add a cover here or Amazon may reject your submission. (They aren’t even going to use the cover here, they’re going to stick in whatever you upload at the KDP site, but they seem to require something be there if you upload a mobi.) You should also fill out as much as you can. Put your blurb in the description field and Use the “tags” section for your keywords, separated by a comma, and they will be included in the metadata, which supposedly Kobo and Apple use for their search.


Click OK and it will return us and you can see the book’s title and author have changed and the new cover shows on the right.


Now we convert to mobi and epub. Click on the brown “convert books button.”


Now before we click ok, we need to change a few things. First go to the Page Setup tab and change the output to “kindle.” (I don’t even know if this is necessary, but it’s how I have it set up because I have a kindle so I’m telling you to do the same.)


Now click on the Table of Contents button.


We now want to click on the magic wand next to the Level 1 TOC line.


This is going to open up a box, use the pull down menu and select H1


Click ok. Remember we put our chapter headings into Header1 style? This is telling calibre that anything in that style should be turned into a chapter heading and put in the Table of Contents. (This may not be necessary.)

Here’s a tip if you’re creating a bundle. Calibre will create a multilayered table of contents if you need one. Just like we used Header 1 for our chapter titles, you can also add Header 2, Header 3, and so on. Then just use H2, H3, etc in Calibre to set the individual levels. In a regular book, your chapter titles are Header 1. In a bundle, you’d make the book titles Header 1, then the chapter titles Header 2. (People will really appreciate this in a bundle. I’m currently reading a trad published bundle of a very popular young adult series and the NCX TOC only includes the first book and it’s very irritating.)

One last thing, you need to change the output format at the top right. You use mobi for the Amazon store. There’s another amazon format, AZW, do not use this. Use mobi. Select it and click ok and it will grind away for a few moments doing the conversion.


Now click on the convert button again. This time change the input format on the left to mobi and the output format to epub and click ok a second time. (Going direct to epub can result in validation errors if you have any links in the book.)

Now we need to get our books to somewhere we can find them. To do this, click on the “save to disk” button.


Select somewhere to put the books, your desktop or the documents folder. It will copy a folder with all the different formats to that spot.

That’s it or at least we hope it is. The mobi for Amazon is very reliable, but make sure to download the offline kindle previewer and look at your file.

Epubs are a bit more finicky. Validate the epub, mine have worked, but I can’t vouch for what Apple will make of it as they reject files that pass other converters.

Obviously, if you have an ereader. Take a peek. I always look at my epubs in Adobe Digital Editions and the Nook application. One additional note here, if you test the epub file on devices be careful of Itunes. When Itunes adds an epub to its library, it adds special Apple specific code to the original file that will cause the epub to fail validation everywhere else. If you’re going to preview on your ipad or iphone, make a copy of the epub and don’t get the original and apple versions mixed up. Use the original file, not the one you imported into Itunes.

Once they validate, upload the mobi to Amazon and the epub everywhere else. Congrats!

So what if your epub doesn’t validate? Well, the next step is to play some pingpong. Remember how we changed the input to mobi and the output to epub? Run it through the converter. Epub back to mobi, mobi to azw, azw to epub. (Don’t convert to html or docx or you’ll end up with multiple tables of contents.) Calibre is open source software and each of these converters is a little different and designed to get you a good result. If the straight mobi to epub doesn’t do it quite right, chances are that running it through several times will fix the problem. This was a much bigger problem when we were converting from html, but Calibre’s docx conversion is pretty damned good in my experience.

If this doesn’t work, Calibre has a secret weapon: an editor. Right click on the title and select “edit book” then select epub. If you’re familiar with HTML you’ll be right at home, but you should be able to understand what’s going on if you just take a deep breath and look. Look at the validator output, it will tell you which file inside the epub is the problem and what line on that file is the problem. Chances are you can just remove whatever tag is there. Sigil is another popular editor that will open and epub and let you monkey around in it.

You can also tweak your document here if you know html and css. For example, the current generation of devices support drop caps and you can insert those here. I’ve also had one book that had extensive emails in it and I set up a new style with the text set as sans-serif and went through and found the emails and reformatted them. (You shouldn’t try to define what font a book uses, but it’s safe to mark something as sans-serif. The device will use its native sans font or if it doesn’t have one, it will ignore it.) If you decide to make these kinds of changes, you will want to convert from the epub that you’ve just edited back to mobi.

Good luck and please let me know if this works for you!

If you’ve made it to the end, I also offer up some files as examples.

The original Word docx file

The mobi

The epub