How to format a screenplay or drama for the Kindle

When I posted a link to the Nurse Jackie screenplay earlier this month, someone left a comment asking for help with formatting screenplays for the Kindle.

I am always up for a challenge, at least until I grow bored or frustrated, so today I tried to figure out a solution. What I finally came up with is a bit convoluted, but hopefully it lays the groundwork for others to figure out more elegant solutions in the future.

First, I just played around with sending pdf, html, and txt files to Amazon to let them convert it to see what happened. The results were not good. I did a search online for advice on conversions and saw someone mention using FinalDraft–something about how you can set up the style guide with that program and export a correctly formatted document that can then be used by the Kindle.

Well I’m not paying $$$ for FinalDraft obviously. Instead, I remembered an open-source and free-as-in-beer alternative, Celtx. I figured I’d try that. It’s available for Windows, Apple, and Linux platforms.

Next, I went to a website that has html versions of screenplays and downloaded a sample script. (Note that I didn’t try any pdf documents–someone else will have to try that, as I’ve exhausted my curiosity for this problem today.)

Finally, I relied on Calibre, another free software, that manages ebooks for a variety of devices. It also handles conversions.

Once I had all the raw materials–html version of screenplay, Celtx screenplay formatting software, and Calibre ebook software–I started experimenting.

My Solution

Update November 2010: I left out a critical step below, which is that you have to convert your HTML script to a .txt file before Celtx will let you import it. The tricky thing is, if you try cutting and pasting directly into Celtx, you’re likely to lose all the nice line spacing that Celtx uses to mark up the script. The quickest way I found to get the type of conversion you want is to drag the html script into a blank browser window so that it renders all the formatting, then select all the text and copy-paste it into a blank word processing document in Word, OpenOffice, NeoOffice, etc. Now save that document as a text only .txt file (if you have the option of whether or not to preserve spacing, say yes). Now that .txt file should work when you import it into Celtx.

Summary for the technically inclined: Import in Celtx, export as html, replace CSS code in exported doc with this code (modify as per your tastes), import into Calibre, convert to MOBI, send to device.

  1. In Celtx

    1. import html .txt version of a screenplay (see the special note in the dashed box above)
    2. export it as html

    Why? Because by doing this, you get Celtx to replace whatever formatting the original document used with a consistent set of CSS mark-up tags, which is important to have in order to get the Kindle to display the formatting properly.

  2. Open the newly exported html file in a simple text editor, e.g. WordPad on Windows XP, or in a real HTML editing application (note that fancier editors like Microsoft Word may hide the html code from you, and really really simple editors like Notepad may do the same)
    1. delete ALL the current CSS style code — everything between <style type=”text/css”> and </style> — from the top of the document (make sure you don’t actually delete the “style” tags as well)
    2. paste this CSS code instead
    3. save the file
  3. In Calibre
    1. Import this new html file (or drag and drop it into your list of documents and it will be copied over automatically
    2. Highlight the file in the Calibre list by clicking on it once
    3. Click the big “Convert E-books” button at top of screen
    4. Click “Page Setup” and change Destination profile to Kindle
    5. Hit Okay
    6. Wait for hourglass in the bottom right corner to stop spinning
    7. Right click the file name in the Calibre list
    8. Select “Send to device”

    That’s it! It probably looks more complicated than it is, because I’m trying to include enough detail here for beginners to use these instructions.

    I experimented with the CSS style code for a while until I got something that worked for me, but I noticed a couple of weird issues with it:

    • The Kindle seems to ignore right-side margins
    • Although I used percentages in the CSS style code, hoping it would scale appropriately when different text sizes are used, it doesn’t seem to work that way. The CSS I settled on looks good when the text display size on the Kindle is at one of the smallest two settings, but on the bigger settings the left-side margins start to get really obnoxious. It’s a puzzle to me.

    And finally, here are two things I noticed that you should be aware of:

    • The final version will only be as good as the original screenplay you export from Celtx. If the formatting isn’t correct there, clean it up there and make sure everything’s standardized before exporting it. Otherwise, the CSS markup tags won’t be used correctly throughout the document.
    • You can change that CSS code to whatever you want. If you don’t like the margins I chose, simply play around with the CSS code before you import the file into Calibre for conversion. The primary three areas you’ll want to play with are marked p.character, p.parenthetical, and p.dialog. Also, I stripped out a lot of other CSS code to make this simpler; it’s possible you can customize the code to include far more elaborate mark-up rules, so long as you always reference the tags that Celtx uses.

    (Photo: Vikki Heartbreak)

    This entry was posted in how to, movies and tagged , , , , , , . Bookmark the permalink.

    15 Responses to "How to format a screenplay or drama for the Kindle"

    Leave a replyLeave a Reply to Will P

    − 5 = zero