A lightweight WordPress plugin designed to optimize your website by removing unnecessary scripts, styles, and header elements that can slow down your site.
- Header Cleanup: Remove WordPress version, WLW manifest links, and shortlinks
- Script Optimization: Disable WordPress emojis and remove jQuery Migrate
- Style Optimization: Remove inline styles from recent comments widget and disable classic theme styles
- DNS Prefetching: Add DNS prefetch for common external domains to improve load times
- Jetpack Optimization: Remove Jetpack advertisements and promotions
- Download the latest release from the releases page
- Upload the plugin files to the
/wp-content/plugins/simple-wp-optimizer
directory - Activate the plugin through the 'Plugins' menu in WordPress
- Configure the plugin settings via the 'WP Optimizer' menu
composer require enginescript/simple-wp-optimizer
- Navigate to the WP Optimizer menu in your WordPress admin dashboard (under Settings)
- Enable the optimization features you want to use
- Configure the DNS Prefetch domains if needed
- Save your changes
- Settings Page: Configure which optimizations to enable
- Header Cleanup Options: Remove unnecessary elements from WordPress headers
- Performance Options: Disable emojis and jQuery Migrate
- DNS Prefetch Configuration: Add domains for DNS prefetching
Simple WP Optimizer is designed to be compatible with most WordPress themes. The optimizations focus on removing unnecessary WordPress elements rather than modifying theme functionality.
jQuery Migrate is a script that helps maintain backward compatibility with older jQuery code. Modern themes and plugins generally don't need it, so removing it can improve load time without affecting functionality in most cases.
This option removes emoji-related scripts and styles that WordPress adds by default. Most websites don't need these resources, so removing them can reduce HTTP requests and improve page load time.
Yes, hiding the WordPress version can provide a minor security benefit by making it slightly more difficult for potential attackers to identify vulnerability targets based on your WordPress version.
- PHP 7.4 or higher
- WordPress 5.6 or higher
- Composer (for development and testing)
- Clone this repository:
git clone https://github.com/EngineScript/Simple-WP-Optimizer.git
- Install dependencies:
composer install
- Set up the test environment:
bin/install-wp-tests.sh wordpress_test root '' localhost latest
- Run tests:
composer test
This plugin is fully compatible with PHP versions 7.4 through 8.2. For testing with PHP 8.x, we provide a custom PHPUnit runner script that helps avoid common compatibility issues between PHPUnit and newer PHP versions:
# For PHP 7.4 (standard testing)
composer test
# For PHP 8.0, 8.1, and 8.2 (using the custom runner)
composer test:php8
The custom runner automatically detects your PHP version and applies the appropriate compatibility settings.
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the project
- Create your feature branch:
git checkout -b feature/new-optimization
- Commit your changes:
git commit -m 'Add some new optimization'
- Push to the branch:
git push origin feature/new-optimization
- Open a Pull Request
This project is licensed under the GPL-2.0+ License - see the LICENSE file for details.
See CHANGELOG.MD for a list of changes in each release.
- Developed by EngineScript
- Special thanks to all contributors
For support, please open an issue in the GitHub repository or contact us via [email protected].