I don’t often offer tips for writing novels on here mainly because I’ve only written eight or so and only published a few, but I want to talk about RegEx.
As you guys know, I use Scrivener. I use it predominately because I’m a disordered mess of a man who is kept on the rails of productivity through raw discipline and the human equivalent of gutter bumpers. Many of those are friends, family, religious systems, and a long history of experimentation that left me going, “Nope. Never that again.” Scrivener is one of those bumper rails. It’s a long form document editor that allows for aggressive searching, reorganizing chapters, character searches, backstory, research, note cards, and — ultimately — an easy way to integrate chapters. Without Scrivener, there are no callback jokes or moments of foreshadowing in Bell Hammers. Consider that.
You can use RegEx in both Scrivener and Word. And here’s where it turns into several tips for writing novels:
RegEx is a search function typically used in coding. However, when applied judiciously it can help you tremendously with revision. Here’s how this works. The first line will give you an idea of what you’re searching for and the sub-bullet point will show you the code to type in the search bar.
Consider, for instance, if you wanted to search for a paragraph with more than 7 words in it? Why would you want to do this?
Well I did an analysis of Patrick Rothfuss’s The Name of the Wind. Do you know what his average sentence length is? And it’s a standard deviation of 6, mostly skewed towards the shorter.
On average he uses *checks notes* 4-letter words.

I’m teasing, of course. His prose is immaculate for the style he’s chosen.
So if you wanted to skew towards a style like that, here’s the sort of RegEx you’d need to move towards:
- More than 7 sentences in a paragraph (change the 7 to change the length)
- (?:[^\n.!?]*[.!?]){7,}
- Words longer than 9 characters (change the 9 to change the length)
- \w{9,}
- A sentence with more than 10 words (change the 11 to find sentences with 11 or more words in them)
- (?:\b\w+\b[\s,]*){11,}
- A sentence with 3 or more of these transition words, which may indicate a run-on sentence (assuming that’s not the style you want)
- [^.!?]*(?:\b(?:accordingly|and|but|or|additionally|furthermore|afterward|albeit|although|besides|consequently|conversely|even\s+so|even\s+though|further|furthermore|hence|henceforth|however|in\s+addition|indeed|lest|likewise|meanwhile|moreover|nevertheless|nonetheless|notwithstanding|otherwise|rather|still|thereby|therefore|thereupon|thus|whereas|yet)\b[^.!?]*)+[.!?]
- Find all caps words to use them sparingly:
- \b[A-Z]+\b
- In my current manuscript, I had one character named Miah — as in Jeremiah’s nickname — and one character named Mia — as in both Maria and Italian for “mine”. Halfway through I was CONFUSING MYSELF, even though I knew not to do this. Not to even start a character name with the same letter until I’d used up the alphabet and, where possible, seldom in the same scene. Harry. Hermione. Hagrid. Yeah we get it, but it can grow tiresome. So to search for “Mia” and not include “Miah” I needed to find the word “Mia” followed by a space or any punctuation. A simple find and replace would break the manuscript. Consider too words like amia, bulimia, Bohemia, leukemia, and hypomagnesaemia. Okay, magnesium deficiency didn’t come up, but still. Here’s the RegEx I needed:
- Mia(?:\s|\p{P})
- Find words that are repeated within a page (250 words) that aren’t one of the most common 15 words. It’ll make it easy to find where you repeated words:
- (?i)\b(?!the\b|be\b|to\b|of\b|and\b|a\b|in\b|that\b|have\b|i\b|it\b|for\b|not\b|on\b|with\b)([a-z]+)\b(?=(?:\W+[a-z]+){0,249}\W+\1\b)
Any of the first three you can edit by changing the number variable.
Do you have any RegEx searches to share?
What about tips for writing novels?



Comment early, comment often, keep it civil: