Title: Speed optimization question
Last modified: December 30, 2017

---

# Speed optimization question

 *  Resolved [joedarko](https://wordpress.org/support/users/joedarko/)
 * (@joedarko)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/speed-optimization-question/)
 * Hi,
 * i love the plugin and i would like to ask one quick question about best practices
   when it comes to website loading speed.
 * Is it OK when i separately add many different custom CSS codes or could it be
   slowing my website down because it has to load everything separately and i should
   rather put all the code into one part?
    _____________________________________
 * How i do it now:
 * Custom CSS 1 (Some code inside)
    Custom CSS 2 (Some code inside) Custom CSS 3(
   Some code inside) . . . Custom CSS 25 (Some code inside) _____________________________________
 * Would it be better like this?
 * Custom CSS 1 (All the code inside)
    _____________________________________
 * Yeah, so i would just like to know if adding all my code as one custom CSS addition
   will have any benefit in terms of loading speed than adding my custom CSS codes
   as many separate additions.
 * Thank you very much for your answer. 🙂

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [SilkyPress](https://wordpress.org/support/users/diana_burduja/)
 * (@diana_burduja)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/speed-optimization-question/#post-9822606)
 * Hi,
 * of course the number of loaded files has an impact on the page load speed, but
   it’s all a matter of balancing code maintainability with page speed.
 * You can also put everything into one CSS Custom code; the page will load fast,
   but if it’s too long, then it might be hard to maintain/modify the CSS code later
   when you want to change something.
 * If you add several inline CSS codes, then the page will still load fast, but 
   then the browser will not be able to cache the CSS codes and load them from the
   cache on the next page load.
 * If you add several external CSS codes, the browser will need to load each of 
   them, which will add several microseconds to the load speed, but then the browser
   caches the files.
 * Definitely it isn’t recommendable to write make a new CSS Custom Code for each
   CSS rule. But splitting the code in several CSS Custom Codes in a logical manner
   will keep the code more maintainable.
 * I personally split the code by functionality. For example I would have a CSS 
   Custom Code for implementing an FAQ section, another to modify the output of 
   a plugin and yet another for modifying a bit the theme.
 * I hope this answers your question.
 *  Thread Starter [joedarko](https://wordpress.org/support/users/joedarko/)
 * (@joedarko)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/speed-optimization-question/#post-9823447)
 * Great, thank you very much for the detailed answer!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Speed optimization question’ is closed to new replies.

 * ![](https://ps.w.org/custom-css-js/assets/icon-128x128.png?rev=1303730)
 * [Simple Custom CSS and JS](https://wordpress.org/plugins/custom-css-js/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/custom-css-js/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/custom-css-js/)
 * [Active Topics](https://wordpress.org/support/plugin/custom-css-js/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/custom-css-js/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/custom-css-js/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [joedarko](https://wordpress.org/support/users/joedarko/)
 * Last activity: [8 years, 5 months ago](https://wordpress.org/support/topic/speed-optimization-question/#post-9823447)
 * Status: resolved