# Autoptimize plugin configuration

[Autoptimize](https://wordpress.org/plugins/autoptimize/) plugin optimizes the pages of your site. It compresses images, caсhes files, minifies JS and CSS. All of the above speeds up page loads. Setka Editor uses specific CSS and JS files when generating pages. Improper optimization may disrupt their operation.

To prevent optimization from changing the look of Setka Editor content, configure Automtimize according to this guide.

## Which CSS files Setka Editor uses <a href="#h_01f24n0s6vm35gp118whhf0fxp" id="h_01f24n0s6vm35gp118whhf0fxp"></a>

Setka Editor uses the following CSS-files and inline blocks:

**Standalone CSS** —  3 CSS files with styles used only in the specific post.

**Standalone critical CSS** — styles of the [first contentful paint](https://developer.mozilla.org/ru/docs/Glossary/First_contentful_paint). Speeds up the rendering of content seen by the user at the very top of the page. 3 inline CSS blocks and 2 CSS files.

**Common CSS** — common rules for all the styles stored on the Setka account. Single CSS file.

**Standalone critical CSS** — styles of the [first contentful paint](https://developer.mozilla.org/ru/docs/Glossary/First_contentful_paint). Speed up the rendering of content that user sees at the very top of the page. 3 inline CSS blocks and 2 CSS files.

{% hint style="warning" %}
The file connection order is critical for Setka Editor. While using the optimizer (Autoptimize or any other) in the **Standalone** or **Standalone critical** mode, it is important to keep the order of CSS code: **Common CSS should always come first.**
{% endhint %}

Autoptimize optimizes only the local files. Therefore, enabling Autoptimize for Setka styles makes sense only if the **Enable Setka CDN files** option is not activated in the Setka Editor plugin settings:

![](https://1843290185-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MLOEPbfEK4119w2ROYc%2F-MX8OSSFFQqKe6ugTPyL%2F-MX8PBKHq_Z4cGQy9rhd%2FScreenshot-WordPress-Setka-Editor-Settings-CDN.png?alt=media\&token=682aa8ef-65dd-42e0-a948-5462a35e7f37)

### Should I enable file minification? <a href="#h_01f24n13bdb1g5ndhymh5ry2gc" id="h_01f24n13bdb1g5ndhymh5ry2gc"></a>

Even though Setka CSS files have the \* .css extension, not \*min.css, their content is already minified. Therefore, minification is not necessary. Also, keep in mind that some minifiers can corrupt the CSS code.

## Autoptimize configuration options <a href="#h_01f24n1p9k36vhxds8qj1m8m6f" id="h_01f24n1p9k36vhxds8qj1m8m6f"></a>

Autoptimize settings depend on what [type of CSS](#h_01F24N0S6VM35GP118WHHF0FXP) you are using: Common, Standalone, or Standalone critical. To select the type of CSS, go to Setka Editor WordPress plugin settings:

![](https://1843290185-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MLOEPbfEK4119w2ROYc%2F-MX8OSSFFQqKe6ugTPyL%2F-MX8Pt8ktXmd-lG0kkaD%2FScreenshot-WordPress-Setka-Editor-Settings-Styles.png?alt=media\&token=048b75a4-827d-434d-8d22-5d2b7da14505)

Here:

* **Default. Only load styles needed for a specific Setka Editor post.** — uses Standalone CSS. Set by default.
* **Inline critical post styles into a page and load the rest of the styles asynchronously.** — uses Standalone critical CSS.
* **Legacy. Load a combined CSS file with all your Setka Editor styles.** — uses Common CSS. Dated option. May slow down page loading, hence, not recommended.

### For Common CSS <a href="#h_01f24n238mjz661ve936n50k7t" id="h_01f24n238mjz661ve936n50k7t"></a>

If Common CSS is used, go to Autoptimize WordPress plugin settings and set the following in the **CSS Options** block:

* Activate the **Aggregate CSS-files** option.
* Make sure that, the **Exclude CSS from Autoptimize:** field does not contain the `wp-content/uploads/` string. If it is present, remove it.

![](https://1843290185-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MLOEPbfEK4119w2ROYc%2F-MX8OSSFFQqKe6ugTPyL%2F-MX8Q-CA3VoNBixljyHX%2FScreenshot-WordPress-Autoptimize-CSS-Options-Common.png?alt=media\&token=6a47e5c9-17db-4602-86e4-a46c36e1bb04)

### For Standalone CSS <a href="#h_01f24n29d7pjbpjq1v5z05t788" id="h_01f24n29d7pjbpjq1v5z05t788"></a>

If Standalone CSS is used, go to Autoptimize WordPress plugin settings and set the following in the **CSS Options** block:

* Activate the **Aggregate CSS-files** option, if you are sure, Setka CSS files should be combined into one file with all other styles on the page. This optimization is redundant in some cases. Setka CSS files already contain a minimal number of styles. If the option is activated, a different combination of 3 files will be used on each page. Therefore, the effect of accelerating the rendering of the first screen in some cases will be overridden by the lack of cache.
* Make sure that, the **Exclude CSS from Autoptimize:** field does not contain the `wp-content/uploads/` string. If it is present, remove it.

![](https://1843290185-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MLOEPbfEK4119w2ROYc%2F-MX8OSSFFQqKe6ugTPyL%2F-MX8QMZT2WnqJ2urj2_o%2FScreenshot-WordPress-Autoptimize-CSS-Options-Standalone.png?alt=media\&token=9edb5266-b13a-4ac6-be8e-4c16d6860d0c)

### For Standalone critical CSS <a href="#h_01f24n2e5ktm06ncj98kkm2es2" id="h_01f24n2e5ktm06ncj98kkm2es2"></a>

In Standalone critical mode, Setka styles are optimized the same way as if they were optimized by Autoptimize. Therefore, it is not necessary to apply optimizations to Standalone critical styles. You can configure Autoptimize in 2 ways:

#### Minify all styles <a href="#h_01f24n2mhwnms8xgma19wektkc" id="h_01f24n2mhwnms8xgma19wektkc"></a>

Use these settings if you need to combine and minify not only Setka styles but all other styles on the page.

Go to Autoptimize WordPress plugin settings and set the following in the **CSS Options** block:

* Activate the **Aggregate CSS-files?** option.
* Activate the **Also aggregate inline CSS?** option.
* Make sure that, the **Exclude CSS from Autoptimize:** field does not contain the `wp-content/uploads/` string. If it is present, remove it.

#### Minify all styles, except Setka styles <a href="#h_01f24n2tnvdcr90738965e9xa5" id="h_01f24n2tnvdcr90738965e9xa5"></a>

Use these settings when you need to combine and minify all styles except Setka styles.

Go to Autoptimize WordPress plugin settings and set the following in the **CSS Options** block:

* Activate the **Aggregate CSS-files?** option.
* Disable the **Also aggregate inline CSS?** option.
* Add the `wp-content/uploads/setka-editor/` strig into the **Exclude CSS from Autoptimize:** field.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://setka.gitbook.io/help-center/integrations/setka-and-wordpress/page-load-speed-optimization-settings/autoptimize-plugin-configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
