Skip to content

ACF Administration and Licensing

NASPO ValuePoint intentionally hides the Advanced Custom Fields (ACF) administration interface outside the local development environment.

This is expected production behavior. ACF field groups and site functionality continue to work normally; only the administrative interface used to edit field definitions and manage the license is hidden.

Current Implementation

The parent fritz theme applies the production restriction in:

wp-content/themes/fritz/inc/Base/Acf.php

The relevant logic is:

if ( 'local' !== wp_get_environment_type() ) {
    add_filter( 'acf/settings/show_admin', '__return_false' );
} else {
    acf_update_setting( 'acfe/dev', true );
}

The active naspo theme inherits this behavior from fritz.

Environment ACF administration interface
Local Visible
Production and other non-local environments Hidden

Why the Interface Is Hidden

ACF field definitions are treated as application configuration rather than production-editable content. Hiding the interface helps prevent:

  • Accidental changes to field groups on production
  • Configuration drift between environments
  • Production-only changes that are not represented in the repository
  • Unreviewed changes to fields used by templates, integrations, or content workflows

Do not permanently enable ACF administration on production

Do not remove the theme restriction as a routine workaround. Field-group changes should follow the site's normal development and deployment workflow.

License Maintenance

The hidden interface also prevents routine access to ACF → Updates, where an ACF Pro license can be activated or changed.

When license maintenance is required, Online Services may temporarily expose the ACF interface to one authorized administrator. The approved procedure is to use a narrowly scoped, temporary must-use plugin and remove it immediately after maintenance.

This approach:

  • Leaves the parent and child themes unchanged
  • Keeps the ACF interface hidden from other users
  • Avoids placing the license key in Git or wp-config.php
  • Provides a simple and verifiable rollback

Controlled Temporary Access Procedure

1. Confirm the WordPress root and maintenance user

The production WordPress root is:

/var/www/html

List administrator accounts and identify the user ID for the person performing maintenance:

sudo -u www-data -- wp \
  --path=/var/www/html \
  user list --fields=ID,user_login,roles

2. Confirm the interface is currently hidden

Replace <USER_ID> with the maintenance account's numeric WordPress user ID:

sudo -u www-data -- wp \
  --path=/var/www/html \
  --user=<USER_ID> \
  eval 'echo "show_admin before maintenance: "; var_export( acf_get_setting("show_admin") ); echo PHP_EOL;'

Expected result:

show_admin before maintenance: false

3. Create a temporary user-scoped MU plugin

Replace <USER_ID> in the PHP below before running the command:

sudo mkdir -p /var/www/html/wp-content/mu-plugins

sudo tee /var/www/html/wp-content/mu-plugins/acf-temporary-admin-access.php > /dev/null <<'PHP'
<?php
/**
 * Temporary ACF administration access for approved maintenance.
 *
 * Delete this file immediately after the maintenance task is complete.
 */

add_filter(
    'acf/settings/show_admin',
    function ( $show_admin ) {
        if ( <USER_ID> === get_current_user_id() ) {
            return true;
        }

        return $show_admin;
    },
    999
);
PHP

Validate the temporary file before opening WordPress Admin:

sudo php -l /var/www/html/wp-content/mu-plugins/acf-temporary-admin-access.php

Expected result:

No syntax errors detected in /var/www/html/wp-content/mu-plugins/acf-temporary-admin-access.php

Confirm the override applies only to the maintenance account:

sudo -u www-data -- wp \
  --path=/var/www/html \
  --user=<USER_ID> \
  eval 'echo "show_admin during maintenance: "; var_export( acf_get_setting("show_admin") ); echo PHP_EOL;'

Expected result:

show_admin during maintenance: true

4. Complete the license maintenance

While logged in as the approved administrator:

  1. Refresh WordPress Admin.
  2. Open ACF → Updates.
  3. Activate or replace the approved ACF Pro license.
  4. Confirm the license status is Active.
  5. Confirm the expected license type and update eligibility.
  6. Confirm the production domain appears in the ACF account activation list.

Protect the license key

Do not paste the license key into OSKB, tickets, screenshots, chat messages, Git, or shared configuration files. Store account credentials and license information only in the approved password-management system.

5. Remove the temporary override immediately

sudo rm /var/www/html/wp-content/mu-plugins/acf-temporary-admin-access.php

Confirm the file is gone:

sudo test ! -e /var/www/html/wp-content/mu-plugins/acf-temporary-admin-access.php \
  && echo "Temporary ACF override removed."

Confirm ACF administration is hidden again:

sudo -u www-data -- wp \
  --path=/var/www/html \
  --user=<USER_ID> \
  eval 'echo "show_admin after cleanup: "; var_export( acf_get_setting("show_admin") ); echo PHP_EOL;'

Expected result:

show_admin after cleanup: false

Refresh WordPress Admin and confirm the ACF menu is no longer visible.

Post-Maintenance Verification

Before considering the work complete, verify that:

  • The ACF license reports Active
  • The expected ACF Pro update is available through the normal maintenance workflow
  • The temporary MU plugin has been deleted
  • acf_get_setting( 'show_admin' ) returns false for the maintenance account
  • The public website and WordPress Admin load normally
  • No license key was added to the repository or server configuration files
  • The completed maintenance is recorded in the relevant task or team discussion

Troubleshooting

ACF remains hidden while the temporary plugin exists

Check that:

  • The correct WordPress user ID replaced <USER_ID> in the temporary file
  • The temporary file passed php -l
  • The file is located directly in wp-content/mu-plugins/
  • The maintenance user is logged into the expected account
  • The override uses a later priority than the theme filter, such as 999

WP-CLI reports that /var/www is not a WordPress installation

Use the production WordPress root:

/var/www/html

The production wp-config.php is stored one directory above the WordPress core files at /var/www/wp-config.php. This layout is expected.

WP-CLI refuses to run as root

Run WP-CLI as the web-server account:

sudo -u www-data -- wp --path=/var/www/html <command>

The www-data account does not have an interactive login shell, so do not add -i to this command.

Change History

Date Change
July 18, 2026 Documented the production ACF restriction and validated the temporary user-scoped license-maintenance procedure.