Newsroom Puzzles

CMS

WordPress Install

Embed puzzles on WordPress pages, posts, and custom 404 templates with the block editor or theme files.

WordPress is the most common CMS among small and regional publishers. You can add a Newsroom Puzzles widget through the block editor, a Custom HTML block, or directly in your theme’s 404 template.

Option A: Block editor (pages & posts)

This is the easiest approach for a games page, sidebar column, or standalone puzzle article.

  1. Edit the page or post where you want the puzzle.
  2. Add a Custom HTML block (/ then type “Custom HTML”).
  3. Paste your embed snippet:
    <script src="https://newsroompuzzles.com/embed.js?site=yourpaper.com&game=sudoku"></script>
  4. Update or publish the page.

Tip: Use a wide or full-width template if your theme offers one — puzzles look best with a bit of horizontal space (roughly 300–400px minimum). Add &flat=1 when nesting inside a theme card.

Option B: Custom 404 page

A puzzle on your 404 page keeps readers on-site instead of bouncing. See the dedicated 404 page install guide for copy, testing, and Laravel/Blade examples — or edit 404.php directly:

  1. Go to Appearance → Theme File Editor (or use a child theme).
  2. Open 404.php.
  3. Paste the script tag inside the main content area, below your “Page not found” message:
    <p>While you’re here, try today’s puzzle:</p>
    <script src="https://newsroompuzzles.com/embed.js?site=yourpaper.com&game=sudoku"></script>
  4. Save and test by visiting a URL that doesn’t exist.

Child theme recommended. Editing parent theme files directly means your changes disappear on the next theme update. A child theme keeps the 404 customization safe.

Option C: Plugin-based HTML injection

If you prefer not to touch theme files, plugins like Insert Headers and Footers or WPCode can inject scripts on specific pages. Use their “page-specific” or “conditional” rules to load the embed only on your 404 page or games section.

Set the condition to 404 pages only (or your target page ID) so the script doesn’t load site-wide unnecessarily.

Choosing a game

Change the game parameter to switch puzzles — all use the same script tag:

  • game=sudoku — familiar daily classic
  • game=akari — Nikoli-style logic puzzle
  • game=wordsearch — add &pack=sports or newsroom for themed words
  • game=hangman, memory, game2048

Browse live demos · Full parameter reference

Matching your brand

Add optional theming parameters to the script URL:

<script src="https://newsroompuzzles.com/embed.js?site=yourpaper.com&game=sudoku&theme=dark&accent=%231e3a5f"></script>

theme switches between light and dark mode. accent sets button and highlight colors (URL-encode the # as %23).

Troubleshooting

Widget doesn’t appear

  • Confirm the Custom HTML block wasn’t converted to a paragraph — WordPress sometimes strips <script> tags from non-HTML blocks.
  • Check that a security plugin (Wordfence, etc.) isn’t blocking external scripts.
  • View page source and verify the script tag is present and unmodified.

Layout looks cramped

  • Wrap the script in a container with max-width: 420px; margin: 0 auto; if your sidebar is narrow.
  • Some themes add overflow: hidden on article wrappers — try placing the block outside nested columns.

Stats aren’t updating

  • Make sure site= matches the domain exactly (no www mismatch between embed and what you check).
  • Load the page once in a normal browser — privacy extensions that block all third-party scripts will prevent the analytics ping.

Related

On WordPress VIP? See the WordPress VIP guide. Running Newspack? See Newspack install.