Skip to content

Instantly share code, notes, and snippets.

@vapvarun
Created February 23, 2026 19:18
Show Gist options
  • Select an option

  • Save vapvarun/e95ac5894cf190898e215b0fead326da to your computer and use it in GitHub Desktop.

Select an option

Save vapvarun/e95ac5894cf190898e215b0fead326da to your computer and use it in GitHub Desktop.
wp-config.php Tweaks: 15 Hidden Settings (tweakswp.com)
define( 'WP_MEMORY_LIMIT', '256M' );
define( 'WP_MAX_MEMORY_LIMIT', '512M' );
define( 'WP_POST_REVISIONS', 5 );
define( 'AUTOSAVE_INTERVAL', 120 );
define( 'EMPTY_TRASH_DAYS', 7 );
define( 'DISALLOW_FILE_EDIT', true );
define( 'DISALLOW_FILE_MODS', true );
define( 'FORCE_SSL_ADMIN', true );
define( 'AUTH_KEY', 'unique-phrase-here' );
define( 'SECURE_AUTH_KEY', 'unique-phrase-here' );
define( 'LOGGED_IN_KEY', 'unique-phrase-here' );
define( 'NONCE_KEY', 'unique-phrase-here' );
define( 'AUTH_SALT', 'unique-phrase-here' );
define( 'SECURE_AUTH_SALT', 'unique-phrase-here' );
define( 'LOGGED_IN_SALT', 'unique-phrase-here' );
define( 'NONCE_SALT', 'unique-phrase-here' );
define( 'WP_HTTP_BLOCK_EXTERNAL', true );
define( 'WP_ACCESSIBLE_HOSTS', 'api.wordpress.org,downloads.wordpress.org,*.github.com' );
$table_prefix = 'wp_custom_';
define( 'DISABLE_WP_CRON', true );
*/15 * * * * wget -q -O - https://yoursite.com/wp-cron.php?doing_wp_cron > /dev/null 2>&1
define( 'WP_CRON_LOCK_TIMEOUT', 120 );
// Production-safe debugging — log everything, display nothing
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', false );
define( 'SCRIPT_DEBUG', true );
// Optional: log database queries
define( 'SAVEQUERIES', true );
define( 'AUTOMATIC_UPDATER_DISABLED', true );
// Or control specific update types:
define( 'WP_AUTO_UPDATE_CORE', 'minor' );
define( 'WP_CONTENT_DIR', dirname( __FILE__ ) . '/assets' );
define( 'WP_CONTENT_URL', 'https://yoursite.com/assets' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment