How to Add Reading Time to WordPress
A plugin route and a code route — pick whichever fits your comfort level.
Option 1: Use a plugin (no code)
Plugins like Reading Time WP, WP Reading Time, or general SEO/content suites that include a reading-time block are the fastest route. After installing, most let you set a default WPM (use 238 to match ReadMetric's default) and choose where the estimate displays — typically above the title or next to the byline.
Option 2: A functions.php snippet (full control)
Add this to your theme's functions.php (or a site-specific plugin) to generate a reading time string you can call from any template:
function readmetric_reading_time() {
$content = get_post_field('post_content', get_the_ID());
$word_count = str_word_count(strip_tags($content));
$minutes = ceil($word_count / 238);
return $minutes . ' min read';
} |
Then echo readmetric_reading_time() inside single.php or your theme's post-header template part, near the publish date and author byline.
Where to place it
Show the estimate before the content, near the byline — not buried in a sidebar — so readers see it before committing to scroll. See our reading time & SEO guide for why placement and consistency matter more than the exact WPM you choose.
Checking your number
Paste a finished post into the ReadMetric calculator to sanity-check the plugin or snippet's output before publishing — useful if you've customized the WPM assumption away from the 238 default.