{"id":161872,"date":"2022-09-06T01:44:52","date_gmt":"2022-09-06T01:44:52","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/clean-unused-shortcodes\/"},"modified":"2026-05-21T14:41:50","modified_gmt":"2026-05-21T14:41:50","slug":"clean-unused-shortcodes","status":"publish","type":"plugin","link":"https:\/\/ar.wordpress.org\/plugins\/clean-unused-shortcodes\/","author":16591212,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"2.1.0","stable_tag":"2.1.0","tested":"7.0","requires":"5.8","requires_php":"7.4","requires_plugins":null,"header_name":"Clean unused shortcodes","header_author":"Amr Elarabi","header_description":"This is a short description of what the plugin does. It's displayed in the WordPress admin area.","assets_banners_color":"6737b2","last_updated":"2026-05-21 14:41:50","external_support_url":"","external_repository_url":"","donate_link":"https:\/\/www.paypal.com\/paypalme\/amrelarabi","header_plugin_uri":"https:\/\/amrelarabi.com?ref=clean-unused-shortcodes","header_author_uri":"https:\/\/amrelarabi.com","rating":4.4,"author_block_rating":0,"active_installs":200,"downloads":2872,"num_ratings":7,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.0.0":{"tag":"1.0.0","author":"amrelarabi","date":"2022-09-06 01:44:33"},"1.0.1":{"tag":"1.0.1","author":"amrelarabi","date":"2022-09-06 08:28:22"},"1.0.2":{"tag":"1.0.2","author":"amrelarabi","date":"2024-04-24 04:47:53"},"2.0.0":{"tag":"2.0.0","author":"amrelarabi","date":"2024-12-16 11:31:20"},"2.0.1":{"tag":"2.0.1","author":"amrelarabi","date":"2026-05-17 11:45:21"},"2.1.0":{"tag":"2.1.0","author":"amrelarabi","date":"2026-05-21 14:41:50"}},"upgrade_notice":{"2.1.0":"<p>Major update after 2.0.1: batched scan\/clean, dry-run preview, protected shortcodes, excerpt scanning, registered-but-unused tab, and Gutenberg-aware cleanup. Back up your database before bulk cleaning.<\/p>","2.0.1":"<p>Maintenance release. Tested with WordPress 6.9.4.<\/p>"},"ratings":{"1":1,"2":0,"3":0,"4":0,"5":6},"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":2780409,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.png":{"filename":"icon-256x256.png","revision":2780409,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":2780409,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250.png":{"filename":"banner-772x250.png","revision":2780409,"resolution":"772x250","location":"assets","locale":"","width":722,"height":234}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.0.0","1.0.1","1.0.2","2.0.0","2.0.1","2.1.0"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3534688,"resolution":"1","location":"assets","locale":"","width":1898,"height":695},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3534688,"resolution":"2","location":"assets","locale":"","width":1400,"height":810},"screenshot-3.png":{"filename":"screenshot-3.png","revision":3534688,"resolution":"3","location":"assets","locale":"","width":1453,"height":791}},"screenshots":{"1":"Tools screen with post type selection, scan progress, and results tabs.","2":"Unused shortcodes table with locations, skip option, preview, and clean actions.","3":"Dry-run preview modal showing before and after content."}},"plugin_section":[],"plugin_tags":[83,4657,80,3972,566],"plugin_category":[43],"plugin_contributors":[213469],"plugin_business_model":[],"class_list":["post-161872","plugin","type-plugin","status-publish","hentry","plugin_tags-admin","plugin_tags-clean","plugin_tags-shortcode","plugin_tags-tools","plugin_tags-ui","plugin_category-customization","plugin_contributors-amrelarabi","plugin_committers-amrelarabi"],"banners":{"banner":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/banner-772x250.png?rev=2780409","banner_2x":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/banner-1544x500.png?rev=2780409","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/icon-128x128.png?rev=2780409","icon_2x":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/icon-256x256.png?rev=2780409","generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/screenshot-1.png?rev=3534688","caption":"Tools screen with post type selection, scan progress, and results tabs."},{"src":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/screenshot-2.png?rev=3534688","caption":"Unused shortcodes table with locations, skip option, preview, and clean actions."},{"src":"https:\/\/ps.w.org\/clean-unused-shortcodes\/assets\/screenshot-3.png?rev=3534688","caption":"Dry-run preview modal showing before and after content."}],"raw_content":"<!--section=description-->\n<p><strong>Clean unused shortcodes<\/strong> helps you find and remove shortcode tags left behind by old plugins, themes, or page builders \u2014 without hunting through posts one by one.<\/p>\n\n<p>The tool lives under <strong>Tools \u2192 Clean unused shortcodes<\/strong>. Choose which public post types to scan, review the results, preview changes, then clean individual shortcodes or run a bulk cleanup.<\/p>\n\n<h4>Highlights<\/h4>\n\n<ul>\n<li><strong>Scan by post type<\/strong> \u2014 posts, pages, and other public types (media\/attachments excluded).<\/li>\n<li><strong>Three result tabs<\/strong> \u2014 unused (unregistered) shortcodes, used (registered and found), and registered but unused.<\/li>\n<li><strong>Content and excerpts<\/strong> \u2014 scans both fields and shows where each shortcode appears.<\/li>\n<li><strong>Batched operations<\/strong> \u2014 scan and clean large sites in chunks with a progress bar and cancel option.<\/li>\n<li><strong>Incremental scan<\/strong> \u2014 optionally rescan only posts modified since the last run.<\/li>\n<li><strong>Dry-run preview<\/strong> \u2014 see before\/after snippets per post before saving.<\/li>\n<li><strong>Protected shortcodes<\/strong> \u2014 allowlist tags you never want removed (e.g. <code>caption<\/code>, <code>embed<\/code>).<\/li>\n<li><strong>Skip on clean all<\/strong> \u2014 exclude specific shortcodes from bulk cleanup.<\/li>\n<li><strong>Gutenberg-aware<\/strong> \u2014 removes empty <code>wp:shortcode<\/code> blocks after the inner shortcode is stripped.<\/li>\n<li><strong>Hyphenated names<\/strong> \u2014 detects shortcodes like <code>[my-slider]<\/code> as well as <code>[gallery]<\/code>.<\/li>\n<\/ul>\n\n<h4>Who is this for?<\/h4>\n\n<ul>\n<li>Sites that deactivated plugins but still have <code>[shortcode]<\/code> tags in content.<\/li>\n<li>Editors who want a clear list of where each tag appears before deleting.<\/li>\n<li>Administrators cleaning up legacy content on staging before going live.<\/li>\n<\/ul>\n\n<p>Always <strong>back up your database<\/strong> (or test on staging) before running bulk clean operations.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Install the plugin through <strong>Plugins \u2192 Add New<\/strong> in WordPress, or upload the <code>clean-unused-shortcodes<\/code> folder to <code>\/wp-content\/plugins\/<\/code>.<\/li>\n<li>Activate <strong>Clean unused shortcodes<\/strong> through the <strong>Plugins<\/strong> screen.<\/li>\n<li>Go to <strong>Tools \u2192 Clean unused shortcodes<\/strong>.<\/li>\n<li>(Optional) Set <strong>Protected shortcodes<\/strong> \u2014 one name per line.<\/li>\n<li>Select post types, click <strong>Scan shortcodes<\/strong>, then preview or clean as needed.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"what%20is%20an%20%22unused%22%20shortcode%3F\"><h3>What is an \"unused\" shortcode?<\/h3><\/dt>\n<dd><p>A shortcode tag found in your scanned content that is <strong>not<\/strong> currently registered in WordPress (not in the global <code>$shortcode_tags<\/code> list) and is not on your protected list.<\/p><\/dd>\n<dt id=\"will%20this%20remove%20active%20plugin%20shortcodes%3F\"><h3>Will this remove active plugin shortcodes?<\/h3><\/dt>\n<dd><p>No. Registered shortcodes are listed under <strong>Used<\/strong> or <strong>Registered but unused<\/strong> and are not removed by the clean actions. Only unregistered (orphaned) tags in the <strong>Unused<\/strong> tab are removed.<\/p><\/dd>\n<dt id=\"does%20it%20work%20with%20the%20block%20editor%3F\"><h3>Does it work with the block editor?<\/h3><\/dt>\n<dd><p>Yes. Shortcodes inside the <strong>Shortcode<\/strong> block (<code>wp:shortcode<\/code>) are scanned. After cleaning, empty block wrappers are removed so you do not get blank Shortcode blocks in the editor.<\/p><\/dd>\n<dt id=\"can%20i%20undo%20a%20clean%3F\"><h3>Can I undo a clean?<\/h3><\/dt>\n<dd><p>There is no built-in undo. Use a backup or revision restore if you need to roll back. Use <strong>Preview<\/strong> before cleaning to review changes.<\/p><\/dd>\n<dt id=\"does%20it%20scan%20custom%20post%20types%3F\"><h3>Does it scan custom post types?<\/h3><\/dt>\n<dd><p>Yes. All public post types are available in the selector (attachments are excluded).<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>2.1.0<\/h4>\n\n<ul>\n<li>Rebuilt admin tools UI (reliable vanilla JS; no React dependency on the tools screen).<\/li>\n<li>Post type multiselect \u2014 scan posts, pages, and other public types.<\/li>\n<li><strong>Batched scan and clean<\/strong> with progress bar and cancel for large sites.<\/li>\n<li><strong>Incremental scan<\/strong> \u2014 optionally rescan only posts changed since the last run.<\/li>\n<li><strong>Dry-run preview<\/strong> with per-post before\/after snippets (content and excerpt).<\/li>\n<li><strong>Protected shortcodes<\/strong> allowlist and per-shortcode <strong>skip on clean all<\/strong>.<\/li>\n<li>Result tabs: unused, used, and <strong>registered but unused<\/strong>.<\/li>\n<li>Scan <strong>excerpts<\/strong>; show whether each hit is in content or excerpt.<\/li>\n<li>Detect <strong>hyphenated<\/strong> shortcode names (e.g. <code>my-slider<\/code>).<\/li>\n<li>Remove empty Gutenberg <strong>Shortcode<\/strong> (<code>wp:shortcode<\/code>) blocks after cleaning.<\/li>\n<li>Improved security (capability checks, nonces; no unauthenticated AJAX).<\/li>\n<\/ul>\n\n<h4>2.0.1<\/h4>\n\n<ul>\n<li>Update author name.<\/li>\n<li>Tested with WordPress 6.9.4.<\/li>\n<\/ul>\n\n<h4>2.0.0<\/h4>\n\n<ul>\n<li>Complete plugin rewrite using React for the admin UI.<\/li>\n<li>Preview unused and used shortcodes; location list with edit\/view links.<\/li>\n<li>Clean All for unused shortcodes.<\/li>\n<\/ul>\n\n<h4>1.0.4<\/h4>\n\n<ul>\n<li>Updated admin UI.<\/li>\n<li>Fixed white screen on the tools page.<\/li>\n<\/ul>\n\n<h4>1.0.3<\/h4>\n\n<ul>\n<li>Tested with WordPress 6.1.1.<\/li>\n<\/ul>\n\n<h4>1.0.2<\/h4>\n\n<ul>\n<li>Updated plugin description.<\/li>\n<\/ul>\n\n<h4>1.0.1<\/h4>\n\n<ul>\n<li>Updated donate link.<\/li>\n<\/ul>\n\n<h4>1.0.0<\/h4>\n\n<ul>\n<li>First release.<\/li>\n<\/ul>","raw_excerpt":"Scan your site for orphaned shortcodes and remove them safely from post content and excerpts.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/161872","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=161872"}],"author":[{"embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/amrelarabi"}],"wp:attachment":[{"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=161872"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=161872"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=161872"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=161872"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=161872"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/ar.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=161872"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}