WordPress Boilerplate
Boilerplate is a battle-tested WordPress parent theme built from over 10 years of real-world production use across dozens of websites, including marketing sites, ecommerce builds, subscription platforms, blogs, and custom business websites. It combines classic WordPress theme architecture with a modern Bootstrap 5, SASS, and Vite workflow, giving developers a clean foundation without sacrificing the flexibility that makes WordPress powerful. The result is a fast, configurable, accessible, and highly extensible theme system designed to launch polished websites quickly while still supporting deep customization when a project demands it.
Features
- Bootstrap 5 WordPress boilerplate built for sane parent/child theme development
- Light/dark color modes with OS preference support and menu-link overrides
- Configuration-driven theme architecture powered by
config.php, SASS variables, CSS custom properties, and Vite build config - Vanilla PHP templates that respect WordPress theme best practices
- Responsive layout system with fly-out sidebars, sticky navigation, and rhythm-based spacing
- Modern Vite build system with development/production builds, sourcemaps, minification, and filesize reporting
- Editor parity for front-end, block editor, and WP admin typography/color consistency
Responsive
- Off-Canvas Responsive Asides:
left and right sidebars transform into fixed, fly-out mobile menus with CSS-driven checkbox toggles and backdrop blur overlays - Smart Sticky Navbar:
hides the navbar when scrolling down to maximize screen real estate, reveals it instantly on scroll-up, and compensates for the fixed WP Admin bar - Bootstrap 5 Integration:
complimentary to WordPress/PHP, MPA-compliant, and designed around traditional multi-page WordPress theme rendering - Vertical Rhythm System:
uses a custom CSS--baselinevariable and SASSru()function to maintain strict typographic rhythm that scales responsively across breakpoints - Responsive Typography:
font sizing, spacing, headings, and layout rhythm are tuned through SASS variables instead of one-off component overrides
Theme Features
- Light/dark modes that respect OS preferences and can be overridden by custom menu links
#bp-color-mode-toggle#bp-color-mode-toggle-with-text
- Configuration-driven theming:
PHP-side feature flags and theme behavior are centralized inconfig.php, while SASS variables and CSS custom properties drive runtime layout/color behavior - SASS-driven design system with configuration-driven layout, typography, borders, forms, buttons, link states, and light/dark theme tokens
- Parent/child theme architecture:
child themes can extend or override parent theme behavior while preserving a stable parent baseline - Custom BS5 Navwalker:
fully implements Bootstrap 5 navigation with multi-level dropdowns, dividers, headers, and screen-reader accessibility classes from the WP Menu editor - Editor Parity:
injects specific stylesheets (editor.scss,admin.scss) into the block editor and WP admin to keep typography and colors aligned with the front-end experience
WordPress Features
- Vanilla PHP templates which respect WordPress theme best practices
- Full category/archive/search support
- Full widget support
- Block/classic editor support
- Dynamic Breadcrumbs:
highly configurable breadcrumb system that natively handles custom post types, hierarchical pages, categories, tags, and pagination depths - Search Enhancements:
implements a minimum character limit, defaulting to3, to prevent empty queries from returning all site content, and adds Post Type badges to search results - Smart Excerpts:
custom excerpt generator that intelligently strips Gutenberg blocks and shortcodes, replacing block-level HTML tags with spaces to prevent words from mashing together - Inline Reply Forms:
JavaScript intercepts the “Reply” button to dynamically clone and inject the comment form directly under the targeted comment without reloading the page - Theme Action Hooks:
templates expose extension points so child themes can customize behavior without rewriting core parent templates
Media & Content
- Fancybox Lightbox:
modern lightbox and gallery support for WordPress galleries, image blocks, and explicit lightbox links - Gallery Captions:
captions are pulled from figure markup, image metadata, titles, or alt text when available - Intersection Observer Lazy Loading:
native lazy loading for images with.lazyclasses, falling back to a throttled scroll listener for older browsers - Dedicated Print Stylesheet:
print.scsshides navbars, sidebars, and comments, switches text to high-contrast black, and prints hyperlinkhrefvalues next to links
Accessibility
- Screen-Reader Optimization:
extensive use ofaria-expanded,aria-hidden, and.visually-hiddenclasses across toggles, pagination, nav, and forms - Keyboard-Friendly Navigation:
Bootstrap 5 navigation patterns, visible link states, and accessible menu controls are preserved across light and dark themes - Translation-Ready Output:
template strings and escaped output follow WordPress theme conventions
Optimizations
- Performance & Bloat Removal:
automatically disables WP emojis, oEmbed auto-discovery scripts, and REST API header links to keep the front-end clean - Minified/Tersed Assets:
production builds generate optimized JS and CSS assets for front-end delivery - Self-Hosted Font Assets:
Bootstrap Icons and Open Sans are copied into stable theme-controlled output paths - Stable Asset Contract:
compiled assets are emitted to predictable WordPress paths such asdist/js/theme.js,dist/css/theme.css, anddist/font/...
Build System
- Modern Vite build system
- Watch capable via
npm run watch - Working JS and CSS source maps
- Development and production builds
- Filesize reporting, with accurate gzip expected sizes
vite.plugin.sass_sourcemap.mjshandles SASS-to-CSS sourcemap generation and passes it correctly through PostCSS/Autoprefixer
- Watch capable via
- PostCSS/Autoprefixer Support:
compiled CSS is processed for practical browser compatibility - Build Configuration Separation:
PHP theme behavior lives inconfig.php, while build targets and asset behavior are organized through the Vite/build configuration layer - Validation-Friendly Workflow:
supports PHP linting, JS syntax checks, production build validation, and filesize reporting before commits