-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
The plugin’s settings are split into seven tabs:
- Overview
- Image optimization
- Minification
- Concatenation (Beta)
- Background processes
- Logs
- About
See how all your optimizations are performing at a glance.

Improve your website’s load times by compressing your Media Library images without compromising their quality and converting them to modern formats like WebP and AVIF.

Choose:
- whether you’d like to optimize images on upload
- whether you’d like to keep the original files or delete them when the optimized ones are generated
- which image editor (Imagick or GD) you prefer
- the optimized image quality (lower numbers mean more lossy but smaller filesize, while larger numbers mean almost lossless conversion but larger filesize)
- which file type (WebP or AVIF) you prefer to convert your image files to

To exclude specific images from being optimized, you can add exclusions in the “Image exclusions” section. You can either use absolute URLs or regular expressions to match multiple files.
You can also exclude images programmatically by hooking into the pressidium_performance_image_exclusions filter and returning an array of URLs or regular expressions that match the images you want to exclude.
Improve your site’s performance by reducing the size of your JavaScript and CSS files, ensuring faster load times.

Under the “Minification” tab, you’ll find all the settings for the file minification feature of the plugin.
To exclude specific files from being minified, you can add exclusions in the “Script exclusions” and “Style exclusions” sections. You can either use absolute URLs or regular expressions to match multiple files.
You can also exclude files programmatically by hooking into the pressidium_performance_minification_exclusions_{$file_type} filter and returning an array of URLs or regular expressions that match the files you want to exclude for the specified $file_type (either js or css).
When a non-admin page is requested, the plugin parses the generated HTML and looks for script and style tags. If it finds unminified assets, it queues them for minification in the background. If already minified, it serves the optimized version instead.
Any JS or CSS file that meets the following criteria is minified:
- It is not excluded from minification
- It has not been minified by the plugin before
- It is not already minified (i.e., it does not end with .min.js or .min.css and isn’t a single line of code after pruning)
- It is not empty
- It is a supported file type (JS or CSS)
Minified files are stored in the database along with their last modified time and a hash of the original file contents. These minification records are considered valid for 7 days by default (you can change this by hooking into the pressidium_performance_minification_ttl_in_days filter and setting a different TTL in days). During this period, the plugin will not re-minify the files nor check their hashes, so it will serve the cached minified version directly as long as the URLs remain the same.
After this period, the plugin will check if the original files have changed by comparing their hashes. If they have changed, the plugin will attempt to re-minify them.
Checking the hashes of the original files is a relatively lightweight operation, so it won’t significantly impact your website’s performance. If the hashes match, the plugin will serve the cached minified version without re-minifying the files.
The minified files are stored in the wp-content/uploads/pressidium-performance/minified/ directory. The plugin creates this directory with the correct permissions automatically. For each minified file, one or more subdirectories are also created based on the original file’s location. For example, if the original file was located at https://example.com/some/path/script.js, the minified version will be stored in wp-content/uploads/pressidium-performance/minified/example.com/some/path/script.js.
A record of the minified file is also stored in the WordPress database in the pressidium_performance_optimizations custom table.
If you delete the plugin, those directories and the database records will be removed as well, so you don’t have to worry about leftover files or database entries.
Reduce HTTP requests and speed up loading across your entire site, by combining multiple JavaScript and CSS files into a single bundle.

Under the “Concatenation” tab, you’ll find all the settings for the file concatenation feature of the plugin.
To exclude specific files from being concatenated, you can add exclusions in the “Script exclusions” and “Style exclusions” sections. You can either use absolute URLs or regular expressions to match multiple files.
You can also exclude files programmatically by hooking into the pressidium_performance_concatenation_exclusions_{$file_type} filter and returning an array of URLs or regular expressions that match the files you want to exclude for the specified $file_type (either js or css).
When a non-admin page is requested, the plugin parses the generated HTML and looks for script and style tags. It groups the files by their type (JS or CSS) and computes an aggregated hash of the original files. If there is no record of a concatenated file with the same hash, it queues the files for concatenation in the background. If a record exists, it serves the cached concatenated version instead.
Concatenated files are stored in the database along with their last modified time and an aggregated hash of the original file URLs. That hash is computed based on the URLs of the original files, which is relatively lightweight as it only involves string concatenation and hashing and does not require accessing the file system.
The plugin will re-compute the aggregated hash of the original files every time a non-admin page is requested. If the hash matches an existing record, it serves the cached concatenated version. If it does not match, it will queue the files to be re-concatenated.
The concatenated files are stored in the wp-content/uploads/pressidium-performance/concatenated/ directory. The plugin creates this directory with the correct permissions automatically. The concatenated files are named based on the aggregated hash of the original file URLs, so they will look something like wp-content/uploads/pressidium-performance/concatenated/1234567890abcdef.js or wp-content/uploads/pressidium-performance/concatenated/abcdef1234567890.css.
A record of the concatenated files is also stored in the WordPress database in the pressidium_performance_concatenations and pressidium_performance_pages_concatenations custom tables.
If you delete the plugin, those directories and the database records will be removed as well, so you don’t have to worry about leftover files or database entries.
The plugin intercepts the final HTML output by enabling output buffering early and flushing it just before a response is sent to the client. It parses the generated HTML using the WordPress HTML API and scans all <link> and <script> tags, collects their associated CSS and JavaScript files, and generates a unique hash representing that exact set of assets. If the hash has been seen before, the plugin immediately reuses the existing concatenated bundle.
When a new set of files is detected, each file is added to a queue, and a background process concatenates them avoiding PHP timeouts. JavaScript execution order is preserved by wrapping file contents into functions and storing them in an array for deferred execution.
On subsequent page loads, the plugin swaps out the original script tags and injects inline code that executes the appropriate chunks to mimic how the scripts originally ran.
Stray concatenated files are automatically removed once per day through a scheduled WordPress cron job. During this daily cleanup task, the plugin scans all concatenated files stored on the filesystem and compares them against the entries in the pressidium_performance_pages_concatenations custom table.
Files that are not associated with any page are identified as stray and are deleted along with their related records in the pressidium_performance_concatenations table.
The “Background processes” tab allows you to manage any processes that are currently running in the background.

All processes run seamlessly in the background to minimize site impact, conserve server resources and prevent performance bottlenecks or timeouts.
A background process can be in any of the following states:
- Queued state
- Processing state
- Paused state
- Unknown state

Under the “Logs” tab, you’ll find logs and other information, useful for debugging:
- WordPress version
- PHP version
- MySQL/MariaDB version
- Database default character set and collation
- PHP memory limit
- Imagick version
- GD version
- Logs location
- WordPress installation URL
- Any messages that have been logged by the plugin’s logger