How to Remove or Delete Indents in Kindle eBooks

Those Kindle Indents!

Anyone who has uploaded an ebook to Amazon’s KDP program (in Microsoft Word .doc format) knows what I am talking about. Indents are added to every single paragraph in the entire book! If you are a perfectionist, like myself, formatting a book for Kindle can sometimes be a frustrating experience. Never fear, however, for this article will explain how self publishers can easily learn how to format a book for Kindle, and make it look nice, too.

Now, if you’re self publishing a fiction novel, that little nuisance may not bother you. Most paragraphs in your book will be indented, anyway. Perhaps you’d rather your copyright page not have indented paragraphs, but that is a small enough matter to ignore.

However, if you’re self publishing ebooks with flush left paragraphs (or flush left chapter headings, etc.), the indents that Kindle adds can make your ebook(s) look unprofessional. I recently published Book Formatting for Self-Publishers, A Comprehensive How-To Guide on Kindle, and became aware of just how ugly all of those automatic indents could look. I had spent quite a bit of time formatting the book to look exactly as I’d like it to in my Word .doc, and was not happy that Kindle reformatted my file. Originally, chapter headings were flush left, the first paragraph of each section was flush left, “tips” and “notes” were formatted into block paragraphs, and so on.

When I uploaded the book to Kindle, all of my careful book formatting disappeared! Chapter headings were indented about a quarter inch. All paragraphs were indented. My “tips” and “notes” block paragraphs were indented on the first line–it looked terrible. What to do?

To make a long story short, I discovered that although the KDP platform does automatically add indents to Microsoft Word .docs (the file recommended for upload by KDP), it does not add indents to uploaded .ePub files.

Here’s how I made an .ePub out of my Microsoft Word .doc:

1) Upload the Microsoft Word .doc to the KDP Platform
2) Download the .mobi file that KDP produces to your computer (the .mobi file contains a great NCX file)
3) Upload that .mobi file to Calibre (Calibre is a free ebook management software program, available for download here: http://calibre-ebook.com/)
4) Convert the .mobi to .ePub format in Calibre
5) Using Windows Explorer, convert the ePUB file to a zip file. (Change the file extension from .epub to .zip) **If you’re not sure how to do this, see the end of this article for instructions.
6) Extract the zip file into a folder–let’s name it EPUBFolder. (This folder cannot be located in the ePUB zip file. )
7) For tips on adjusting the cover image, please see the previous post, Downsampled Images in eBooks for PubIt!
8 ) ***Make adjustments to the CSS file (the rest of this post will show you how).
9) Make a new, empty zip file. Copy the mimetype file from the EPUBFolder first, and paste it into your new zip file. Then copy all of the remaining files from your EPUBFolder (except the mimetype file) and paste them into your new zip. Change the .zip extension to .epub.
10) Upload your new .ePub to Kindle and take a look at it. (You can also view it in the Kindle Enhanced Previewer, or even the NOOK for PC viewer.)
11) You’re finished! :)

Those may seem like a lot of steps, but each of them is exceptionally easy to do. For the remainder of this post, I will explain how to change the CSS in your .ePub file to eliminate the indented paragraphs in your Kindle file. While this may sound complicated, it is not.

The best was to make these changes is to use an html editor, such as Microsoft Expression Web, Adobe Dreamweaver, or another html editor. It is also possible to use Notepad, although it may be more difficult to use Notepad, as you will only see the code, and not the end result in WYSIWYG format. One free html editor available online is KompoZer. Although I have never used it (and therefore cannot officially recommend it), it is recommended by a site that also provides information on editing .ePub files. See this article to learn more about it.

***STEP EIGHT: Change the CSS file to eliminate indents in your file

In your html editor, navigate to the EPUBFolder. All of your files have been extracted into this folder. Open the following files:

stylesheet.css
dummy_split_000.html
dummy_split_001.html
dummy_split_002.html
dummy_split_003.html
dummy_split_004.html
dummy_split_005.html
dummy_split_006.html

(You will not work on all of these dummy_split files. You will just use a few of them. I like to adjust the copyright page, the beginning of the book, and perhaps the Table of Contents (especially if it is generated by Microsoft Word).)

In Microsoft Expression Web I am able to see both the code and the text as it will look in an ereader. Here is an example (looking at the same piece of text in both code and design layout):

Page Before Indents Adjusted:

Before Kindle Indents Deleted

Now we’ll get down to the nitty gritty. You will notice that code has been underlined in the top portion of the image. The CSS style code p class=”calibre5″ affects “PART,” which is also underlined. The ereader WYSIWYG format is below, and an arrow points to “PART.” You can see that it is indented. Similarly, p class=”calibre15″ modifies “First, a little bit of background.” And so on.

The CSS code calibre15, calibre5, and several others need to be modified in order to eliminate the different indents. We will work with calibre15, but the same steps can be applied to all other CSS codes that need to be fixed.

CSS Code Before Modified:

CSS with Kindle Indents

The arrow is pointing to text-indent: 1.5em. In order to delete the indents, change this code to read text-indent: 0 as shown in the following image. Save the CSS file.

CSS Code After Modified:

CSS without Kindle Indents

Page After Indents Adjusted:

After all of the CSS is modified, and the stylesheet.css file has been saved, the results are much better.

Kindle Indents Deleted

You’ll probably want to go through all of the pages in your document, just to make sure the indents look correct on each page. The one page where you might run into a problem is the Table of Contents page, particularly if it is specially formatted by Microsoft Word’s automatic ToC generator. It may have fancy indents that you would like to keep, and yet they may be formatted with the same CSS code (such as calibre15) that we just modified to delete the indent! What to do in this situation?

Simple enough. Make a whole new CSS style for each indent in your ToC. For example, copy the entire calibre15 code, paste it in the stylesheet.css file after calibre15, and rename it calibre1555, for example. Change the calibre1555 text-indent to 1.5em, or whatever you’d like.

Copy CSS Style for Table of Contents

Save the CSS file. Go to your dummy_split page for your ToC. Find all calibre15, and replace it with calibre1555. See if the indent is to your liking. If not, change it again.

Next, go on to Step Nine, listed above, to finish putting together your .ePub file for upload to the Kindle KDP Platform.

I hope this post on how to self publish a book on Kindle has been helpful–it certainly is long! If you have any questions, please leave a comment, and I’ll clarify anything that needs it.

Thanks for reading!

** Rename file extensions:
In order to change the file extensions from .zip to .epub, Windows Explorer must show the file extensions of each file. To turn on this feature, in Windows Explorer (Microsoft Windows 7) go to Organize (or My Computer in earlier versions). Click on “Folder and Search Options” (or Tools, then “Folder Options”), and then click the View tab. Uncheck the box next to “Hide extensions for known file types.”

Now all file extensions should be visible and editable, via the “Rename” file feature.

This entry was posted in Book Formatting, Format a Book, Format eBooks, How to Self Publish a Book, Self Publishing and tagged , , , , , , , , , , . Bookmark the permalink.

Leave a Reply