How to Remove Inline CSS from Astra?

How to Remove Inline CSS from Astra?

The following filter will remove inline CSS generated by the Astra theme and Astra Pro plugin. Paste the following code into the child theme’s functions.php file

IMPORTANT NOTE: This filter will remove all the inline CSS added by Astra which will affect the styling of your website.

function astra_force_remove_style() {
    wp_dequeue_style( 'astra-theme-css' );
    wp_dequeue_style( 'astra-addon-css' );
}

add_action( 'wp_enqueue_scripts', 'astra_force_remove_style', 99 );
Astra_removing_inline-CSS

If you are facing any error while updating the code or you are still unable to remove the inline CSS from your website, please reach out to us and we will be happy to take a look at your website.

Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

On this page

Take the First Step Toward Success Now.

You’re backed by an amazing team and a risk-free money-back guarantee!

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

This field is required.

REWIND

YEAR IN REVIEW

Scroll to Top
Now choose your preferred
page builder addon
Choose your preferred page builder addon

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

Download Free Astra Theme - Modal Popup Form