Title: Admin scripts loading on frontend
Last modified: September 15, 2022

---

# Admin scripts loading on frontend

 *  Resolved [Jure](https://wordpress.org/support/users/jurero123/)
 * (@jurero123)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/admin-scripts-loading-on-frontend/)
 * Hi,
 * I am facing a really weird issue and can’t think of what might be causing it (
   only on Woo >= 6.9). I am using [https://roots.io/bedrock/](https://roots.io/bedrock/).
 * The problem happens only when a user is signed in. Screenshot of files to be 
   loaded: [https://ibb.co/mcZmyK9](https://ibb.co/mcZmyK9)
 * It looks like those scripts are being output in the wp_head() section: [https://ibb.co/rtrpWvq](https://ibb.co/rtrpWvq)
 * I have tried switching to default “storefront” theme and disabling most of the
   plugins, but issue is still there.
 *     ```
       ### WordPress Environment ###
   
       WordPress address (URL): https://pts.loc/wp
       Site address (URL): https://pts.loc
       WC Version: 6.9.1
       REST API Version: ✔ 6.9.1
       WC Blocks Version: ✔ 8.3.2
       Action Scheduler Version: ✔ 3.4.0
       Log Directory Writable: ✔
       WP Version: 6.0.2
       WP Multisite: –
       WP Memory Limit: 512 MB
       WP Debug Mode: ✔
       WP Cron: ✔
       Language: en_US
       External object cache: –
   
       ### Server Environment ###
   
       Server Info: nginx/1.20.2
       PHP Version: 8.0.16
       PHP Post Max Size: 72 MB
       PHP Time Limit: 120
       PHP Max Input Vars: 8000
       cURL Version: 7.74.0
       OpenSSL/1.1.1k
   
       SUHOSIN Installed: –
       MySQL Version: 8.0.28
       Max Upload Size: 64 MB
       Default Timezone is UTC: ✔
       fsockopen/cURL: ✔
       SoapClient: ✔
       DOMDocument: ✔
       GZip: ✔
       Multibyte String: ✔
       Remote Post: ✔
       Remote Get: ✔
   
       ### Database ###
   
       WC Database Version: 6.9.1
       WC Database Prefix: wp_
       Total Database Size: 35.90MB
       Database Data Size: 23.36MB
       Database Index Size: 12.54MB
       wp_woocommerce_sessions: Data: 0.06MB + Index: 0.02MB + Engine InnoDB
       wp_woocommerce_api_keys: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_woocommerce_attribute_taxonomies: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_woocommerce_downloadable_product_permissions: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_woocommerce_order_items: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_woocommerce_order_itemmeta: Data: 0.05MB + Index: 0.03MB + Engine InnoDB
       wp_woocommerce_tax_rates: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_woocommerce_tax_rate_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_woocommerce_shipping_zones: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_woocommerce_shipping_zone_locations: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_woocommerce_shipping_zone_methods: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_woocommerce_payment_tokens: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_woocommerce_payment_tokenmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_woocommerce_log: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_actionscheduler_actions: Data: 3.02MB + Index: 1.31MB + Engine InnoDB
       wp_actionscheduler_claims: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_actionscheduler_groups: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_actionscheduler_logs: Data: 1.02MB + Index: 0.77MB + Engine InnoDB
       wp_aws_cache: Data: 0.06MB + Index: 0.00MB + Engine InnoDB
       wp_aws_index: Data: 5.13MB + Index: 4.34MB + Engine InnoDB
       wp_cartflows_ca_cart_abandonment: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_cartflows_ca_email_history: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_cartflows_ca_email_templates: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_cartflows_ca_email_templates_meta: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_commentmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_comments: Data: 0.02MB + Index: 0.09MB + Engine InnoDB
       wp_facetwp_index: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_links: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_options: Data: 4.03MB + Index: 0.08MB + Engine InnoDB
       wp_pmxi_files: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_hash: Data: 0.08MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_history: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_images: Data: 0.16MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_imports: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_posts: Data: 0.08MB + Index: 0.00MB + Engine InnoDB
       wp_pmxi_templates: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_postmeta: Data: 4.16MB + Index: 3.61MB + Engine InnoDB
       wp_posts: Data: 3.50MB + Index: 0.38MB + Engine InnoDB
       wp_pts_codes: Data: 0.08MB + Index: 0.08MB + Engine InnoDB
       wp_rank_math_internal_links: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_rank_math_internal_meta: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_term_relationships: Data: 0.09MB + Index: 0.06MB + Engine InnoDB
       wp_term_taxonomy: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_termmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_terms: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_usermeta: Data: 0.05MB + Index: 0.03MB + Engine InnoDB
       wp_users: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_wc_admin_note_actions: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wc_admin_notes: Data: 0.06MB + Index: 0.00MB + Engine InnoDB
       wp_wc_category_lookup: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wc_customer_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wc_download_log: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wc_order_coupon_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wc_order_product_lookup: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_wc_order_stats: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_wc_order_tax_lookup: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wc_product_attributes_lookup: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wc_product_download_directories: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wc_product_meta_lookup: Data: 0.14MB + Index: 0.16MB + Engine InnoDB
       wp_wc_rate_limits: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wc_reserved_stock: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wc_tax_rate_classes: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wc_webhooks: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wcpdf_invoice_number: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wdr_order_discounts: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wdr_order_item_discounts: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wdr_rules: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfblockediplog: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfblocks7: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_wfconfig: Data: 0.09MB + Index: 0.00MB + Engine InnoDB
       wp_wfcrawlers: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wffilechanges: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wffilemods: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfhits: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_wfhoover: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wfissues: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_wfknownfilelist: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wflivetraffichuman: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wflocs: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wflogins: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wfls_2fa_secrets: Data: 0.02MB + Index: 0.02MB + Engine InnoDB
       wp_wfls_settings: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfnotifications: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfpendingissues: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_wfreversecache: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wfsnipcache: Data: 0.02MB + Index: 0.05MB + Engine InnoDB
       wp_wfstatus: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wftrafficrates: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_woocommerce_gc_activity: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_woocommerce_gc_cards: Data: 0.02MB + Index: 0.06MB + Engine InnoDB
       wp_woocommerce_gc_cardsmeta: Data: 0.02MB + Index: 0.03MB + Engine InnoDB
       wp_wpmailsmtp_debug_events: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
       wp_wpmailsmtp_tasks_meta: Data: 0.02MB + Index: 0.00MB + Engine InnoDB
   
       ### Post Type Counts ###
   
       acf-field: 91
       acf-field-group: 20
       attachment: 803
       cbk_cashback: 2
       cbk_cashback_log: 2
       cbk_master_log: 2
       cwginstocknotifier: 7
       nav_menu_item: 36
       page: 26
       pokemon-cards: 2
       post: 8
       product: 421
       product_variation: 3
       revision: 140
       shop_coupon: 2
       shop_order: 25
       wp_global_styles: 2
       wpcf7_contact_form: 1
   
       ### Security ###
   
       Secure connection (HTTPS): ✔
       Hide errors from visitors: ✔
   
       ### Active Plugins (7) ###
   
       Query Monitor: by John Blackbourn – 3.10.1
       Advanced Custom Fields PRO: by Delicious Brains – 5.12.3
       Advanced Woo Search: by ILLID – 2.62
       Contact Form 7: by Takayuki Miyoshi – 5.6.3
       FacetWP: by FacetWP
       LLC – 3.9.5
   
       CURCY - WooCommerce Multi Currency Premium: by VillaTheme – 2.1.36
       WooCommerce: by Automattic – 6.9.1
   
       ### Inactive Plugins (20) ###
   
       Back In Stock Notifier for WooCommerce | WooCommerce Waitlist Pro: by codewoogeek – 2.7
       Cashback for WooCommerce: by FantasticPlugins – 2.5
       JSM's Show Post Metadata: by JS Morisset – 3.0.4
       Payment Plugins for Stripe WooCommerce: by Payment Plugins
       support@paymentplugins.com – 3.3.26
   
       Permalink Manager Pro: by Maciej Bis – 2.2.16
       Preview E-mails for WooCommerce: by Digamber Pradhan – 2.1.0
       Quantity Discounts & Pricing For Woocommerce: by Plugify – 2.0.1
       Rank Math SEO: by Rank Math – 1.0.97
       Redirection: by John Godley – 5.3.4
       Regenerate Thumbnails: by Alex Mills (Viper007Bond) – 3.1.5
       Show Current Template: by JOTAKI Taisuke – 0.4.6
       W3 Total Cache: by BoldGrid – 2.2.4
       WooCommerce Cart Abandonment Recovery: by CartFlows Inc – 1.2.19
       WooCommerce Gift Cards: by WooCommerce – 1.10.2
       WooCommerce PayPal Payments: by WooCommerce – 1.9.3
       WooCommerce PDF Invoices & Packing Slips: by WP Overnight – 2.16.0
       Wordfence Security: by Wordfence – 7.6.1
       WP All Import - WooCommerce Import Add-On Pro: by Soflyy – 3.3.1
       WP All Import Pro: by Soflyy – 4.7.3
       WP Mail SMTP Pro: by WPForms – 3.4.0
   
       ### Dropin Plugins (1) ###
   
       db.php: Query Monitor Database Class (Drop-in)
   
       ### Must Use Plugins (2) ###
   
       Bedrock Autoloader: by Roots – 1.0.3
       Register Theme Directory: by Roots – 1.0.0
   
       ### Settings ###
   
       API Enabled: –
       Force SSL: –
       Currency: USD ($)
       Currency Position: right_space
       Thousand Separator: .
       Decimal Separator: ,
       Number of Decimals: 2
       Taxonomies: Product Types: external (external)
       grouped (grouped)
       simple (simple)
       variable (variable)
   
       Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog)
       exclude-from-search (exclude-from-search)
       featured (featured)
       outofstock (outofstock)
       rated-1 (rated-1)
       rated-2 (rated-2)
       rated-3 (rated-3)
       rated-4 (rated-4)
       rated-5 (rated-5)
   
       Connected to WooCommerce.com: –
       Enforce Approved Product Download Directories: –
   
       ### WC Pages ###
   
       Shop base: #7 - /shop/
       Cart: #8 - /cart/
       Checkout: #9 - /checkout/
       My account: #10 - /my-account/
       Terms and conditions: ❌ Page not set
   
       ### Theme ###
   
       Name: Storefront Child
       Version: 2.9.0.1607436788
       Author URL: https://woocommerce.com/
       Child Theme: ✔
       Parent Theme Name: Storefront
       Parent Theme Version: 4.1.3
       Parent Theme Author URL: https://woocommerce.com/
       WooCommerce Support: ✔
   
       ### Templates ###
   
       Overrides: storefront-child-theme/woocommerce/archive-product.php
       storefront-child-theme/woocommerce/cart/cart-empty.php
       storefront-child-theme/woocommerce/cart/cart-totals.php
       storefront-child-theme/woocommerce/cart/cart.php
       storefront-child-theme/woocommerce/cart/proceed-to-checkout-button.php
       storefront-child-theme/woocommerce/checkout/form-billing.php
       storefront-child-theme/woocommerce/checkout/form-checkout.php
       storefront-child-theme/woocommerce/checkout/form-coupon.php
       storefront-child-theme/woocommerce/checkout/review-order.php
       storefront-child-theme/woocommerce/checkout/thankyou.php
       storefront-child-theme/woocommerce/content-product.php
       storefront-child-theme/woocommerce/content-single-product.php
       storefront-child-theme/woocommerce/emails/admin-new-order.php
       storefront-child-theme/woocommerce/emails/customer-completed-order.php
       storefront-child-theme/woocommerce/emails/customer-on-hold-order.php
       storefront-child-theme/woocommerce/emails/customer-refunded-order.php
       storefront-child-theme/woocommerce/emails/customer-reset-password.php
       storefront-child-theme/woocommerce/emails/email-footer.php
       storefront-child-theme/woocommerce/emails/email-header.php
       storefront-child-theme/woocommerce/emails/email-styles.php
       storefront-child-theme/woocommerce/global/form-login.php
       storefront-child-theme/woocommerce/loop/loop-end.php
       storefront-child-theme/woocommerce/loop/loop-start.php
       storefront-child-theme/woocommerce/myaccount/dashboard.php
       storefront-child-theme/woocommerce/myaccount/form-edit-account.php
       storefront-child-theme/woocommerce/myaccount/form-edit-address.php
       storefront-child-theme/woocommerce/myaccount/form-lost-password.php
       storefront-child-theme/woocommerce/myaccount/form-reset-password.php
       storefront-child-theme/woocommerce/myaccount/lost-password-confirmation.php
       storefront-child-theme/woocommerce/myaccount/my-address.php
       storefront-child-theme/woocommerce/order/order-details.php
       storefront-child-theme/woocommerce/single-product/add-to-cart/simple.php
       storefront-child-theme/woocommerce/single-product.php
   
       ### Admin ###
   
       Enabled Features: activity-panels
       analytics
       coupons
       customer-effort-score-tracks
       experimental-products-task
       experimental-import-products-task
       experimental-fashion-sample-products
       experimental-product-tour
       shipping-smart-defaults
       shipping-setting-tour
       homescreen
       marketing
       mobile-app-banner
       navigation
       onboarding
       onboarding-tasks
       remote-inbox-notifications
       remote-free-extensions
       payment-gateway-suggestions
       shipping-label-banner
       subscriptions
       store-alerts
       transient-notices
       wc-pay-promotion
       wc-pay-welcome-page
   
       Disabled Features: minified-js
       new-product-management-experience
       settings
   
       Daily Cron: ✔ Next scheduled: 2022-09-16 08:46:11 +00:00
       Options: ✔
       Notes: 81
       Onboarding: completed
   
       ### Action Scheduler ###
   
       Complete: 4,836
       Oldest: 2022-08-29 10:18:17 +0000
       Newest: 2022-09-15 09:01:29 +0000
   
       Failed: 4
       Oldest: 2022-09-15 05:42:20 +0000
       Newest: 2022-09-15 06:00:06 +0000
   
       Pending: 6
       Oldest: 2022-09-15 09:06:29 +0000
       Newest: 2022-09-23 20:56:19 +0000
   
       ### Status report information ###
   
       Generated at: 2022-09-15 09:03:03 +00:00
       ```
   
 * Thanks,
    Jure
    -  This topic was modified 3 years, 6 months ago by [Jan Dembowski](https://wordpress.org/support/users/jdembowski/).

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

 *  [Ross Hanney](https://wordpress.org/support/users/rosshanney/)
 * (@rosshanney)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/admin-scripts-loading-on-frontend/#post-16013445)
 * I’m also getting this exact issue on several sites (all of which use Bedrock).
 * After a bit of investigating, I think it might be due to the resource hinting
   for the cart/checkout blocks added here: [https://github.com/woocommerce/woocommerce-blocks/pull/5553](https://github.com/woocommerce/woocommerce-blocks/pull/5553)
 * I think it might have only become a problem in WooCommerce 6.9+ due to the cart/
   checkout blocks now being included in WooCommerce core as of 6.9.0: [https://github.com/woocommerce/woocommerce-blocks/pull/6805](https://github.com/woocommerce/woocommerce-blocks/pull/6805)
 * The issue seems to be that the relative URLs for the WordPress core provided 
   scripts (lodash, react, wp-polyfill etc) seem to assume that `wp-includes` is
   at `https://site.url/wp-includes`, but in my case it’s at `https://site.url/wp/
   wp-includes`, so they all 404.
 * For now, I’ve just temporarily disabled resource hinting altogether, using this:
 * `add_filter( 'wp_resource_hints', '__return_empty_array', 99 );`
 *  [con](https://wordpress.org/support/users/conschneider/)
 * (@conschneider)
 * Engineer
 * [3 years, 6 months ago](https://wordpress.org/support/topic/admin-scripts-loading-on-frontend/#post-16016471)
 * Hi Ross,
 * Your approach is probably the most fitting and your analysis seems sound. Bedrock
   does everything a little differently and it makes sense that there maybe path
   problems. Thank you very much for your input.
 * Kind regards,

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

The topic ‘Admin scripts loading on frontend’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [con](https://wordpress.org/support/users/conschneider/)
 * Last activity: [3 years, 6 months ago](https://wordpress.org/support/topic/admin-scripts-loading-on-frontend/#post-16016471)
 * Status: resolved