WPThumbs
Themes Plugins By purpose By industry Best-of lists Fix it guides
Free Plugin by WP Zone v2.0.16

Custom CSS and JavaScript

Easily add custom CSS and JavaScript code to your WordPress site, with draft previewing, revisions, and minification!

Custom CSS and JavaScript

The facts

Rating
4.7★ from 60
Active installs
10k+
Price
Free
Last updated
12 Aug 2024
Added
Dec 2015
Requires WP
3.5
Tested up to
WP 6.6.7
Downloads
178,996

Our analysis

AI-assisted

Custom CSS and JavaScript is a WordPress plugin that enables you to add site-wide CSS styles and JavaScript code to your WordPress site. It is particularly useful for overriding theme styles and enhancing client-side functionality. The plugin features a code editor with syntax highlighting, AJAX saving, and options to save and preview changes as drafts for users with the necessary permissions.

The plugin also allows users to view and restore past revisions, automatically minifies code for performance, and serves custom code from the filesystem. The Developer Edition offers additional features like dividing code into virtual files, live previews, and file upload/download capabilities. Access to the plugin's features can be controlled based on user roles and capabilities.

Best for: This plugin suits WordPress users looking to customise their site's appearance and functionality through code.

What it does well

  • Allows adding custom CSS and JavaScript site-wide
  • Features a code editor with syntax highlighting
  • Supports draft saving and preview for logged-in users
  • Automatically minifies code for performance
  • User access control based on roles and capabilities

Where it falls short

  • Limited information on specific use cases or user experiences

Verdict

Custom CSS and JavaScript provides a practical solution for users wanting to implement custom code on their WordPress sites, with features that cater to both casual users and developers.

From the developer

WP Zone's own description of Custom CSS and JavaScript, lightly tidied.

This plugin allows you to add custom site-wide CSS styles and JavaScript code to your WordPress site. Useful for overriding your theme’s styles and adding client-side functionality.

Features:

  • Code editor with syntax highlighting and AJAX saving to avoid reloading the editor at each save.
  • Save and preview your CSS and JavaScript as a draft that is only applied to logged-in users with the necessary permissions until you are ready to publish your changes to the public.
  • View and restore past revisions of your CSS and JavaScript.
  • Automatically minify your custom CSS and JavaScript code to reduce file size.
  • For the public, custom CSS and JavaScript code is served from the filesystem instead of the database for optimal performance.

Now available! Custom CSS and JavaScript Developer Edition:

  • Divide your CSS and JavaScript into multiple virtual files to keep your code organized (the code is still served as one CSS and one JS file on the front-end for efficiency).
  • Supports Sassy CSS (SCSS)!
  • Live preview for CSS!
  • Upload and download CSS and JavaScript files, individually or in ZIP files.
  • The developer logo and review/donation links are removed from the editor page in the WordPress admin.

Alternatively, you can manually upload the plugin to your wp-content/plugins directory.

If you like this plugin, please consider leaving a comment or review.

User Access Control

In the Custom CSS and JavaScript WordPress plugin, access to plugin features is determined by user capabilities. Users with the edit_theme_options capability will enjoy full access to all the plugin’s features.

By default, the “Administrator” and “Editor” roles come equipped with the edit_theme_options capability. However, site administrators have the flexibility to customize these capabilities and assign them to other roles or individual users through plugins or custom code.

Furthermore, to provide users with enhanced control, we’ve introduced a custom capability known as wpz_custom_css_js. Users possessing both the wpz_custom_css_js and edit_posts capabilities can be granted access to the plugin’s features.

You may also like these plugins

WP Zone has built a bunch of plugins, add-ons, and themes. Check out other favorites here on the repository and don’t forget to leave a 5-star review to help others in the community decide.

  • Product Sales Report for WooCommerce – set up a custom sales report for the products in your WooCommerce store with toggle sorting options. Including or excluding items based on date range, sale status, product category and id, define display order, choose what fields to include, and generate your report with a click.
  • Export Order Items for WooCommerce – export the order details for each sale in your WooCommerce store. Simplify order fulfillment, generate accounting reports in a few clicks, and download into CSV format for readability and universal compatibility with Export Order Items.
  • Replace Image – keep the same URL when uploading to the WordPress media library
  • Force Update Check for Plugins and Themes -force Update Check for Plugins and Themes forces WordPress to run a theme and plugin update check whenever you visit the WordPress updates page
  • Connect SendGrid for Emails – connect SendGrid for Emails is a third-party fork of (and a drop-in replacement for) the official SendGrid plugin
  • Custom CSS and JavaScript – allows you to add custom site-wide CSS styles and JavaScript code to your WordPress site. Useful for overriding your theme’s styles and adding client-side functionality.
  • Disable User Registration Notification Emails – when this plugin is activated, it disables the notification sent to the admin email when a new user account is registered.
  • Inline Image Upload for BBPress – enables the TinyMCE WYSIWYG editor for BBPress forum topics and replies and adds a button to the editor’s “Insert/edit image” dialog that allows forum users to upload images from their computer and insert them inline into their posts.
  • Password Strength for WooCommerce – disables password strength enforcement in WooCommerce.
  • Potent Donations for WooCommerce – acceptance donations through your WooCommerce store
  • Shortcodes for Divi – allows to use Divi Library layouts as shortcodes everywhere where text comes.
  • Stock Export and Import for WooCommerce – generates reports on the stock status (in stock / out of stock) and quantity of individual WooCommerce products.
  • Random Quiz Generator for LifterLMS – pull a random set of questions from your quiz so users never get the same question twice when retaking or setting up a practice quiz.
  • WP and Divi Icons – adds over 660 custom outline SVG icons to your website. SVG icons are vector icons, so they are sharp and look good on any screen at any size.
  • WP Layouts – the best way to organize, import, and export your layouts, especially if you have multiple websites.
  • WP Squish – reduce the amount of storage space consumed by your WordPress installation through the application of user-definable JPEG compression levels and image resolution limits to uploaded images.

To view WP Zone’s premium WordPress plugins and themes, visit our WordPress products catalog page.

Read the full description on the official page →

Tagged as

Alternatives

Other plugins for developer tooling.

WPCode

WPCode

93

Easily add code snippets in WordPress. Insert header & footer scripts, add PHP code snippets with conditio...

Free 3M+ installs 4.9★ (1,873)
Header Footer Code Manager

Easily add tracking code snippets, conversion pixels, or other scripts required by third party services for an...

Free 600k+ installs 4.9★ (309)
Admin and Site Enhancements

Duplicate post, post order, image resize, email via SMTP, admin menu editor, custom css / code, disable gutenb...

Free 200k+ installs 5★ (421)
Shortcoder

Create custom "Shortcodes" easily for HTML, JavaScript, CSS code snippets and use the shortcodes wit...

Free 100k+ installs 4.9★ (227)
Insert PHP Code Snippet

Add PHP code to your pages and posts easily using shortcodes.

Free 90k+ installs 4.9★ (705)
Code Snippets

An easy, clean, and simple way to enhance your site with code snippets.

Free 1M+ installs 4.7★ (509)